Compare commits

...

3 Commits

Author SHA1 Message Date
3355683609
ci: update submodule references
All checks were successful
build / build (push) Successful in 1m56s
Submodules Sync / sync (push) Successful in 8s
build / trigger-build-image (push) Successful in 6s
2024-10-08 16:20:24 -04:00
8ed89b7be7
chore: update pre-commit hooks 2024-10-08 16:02:01 -04:00
3c2fa7ebda
docs: update connection problem solution 2024-10-08 15:59:26 -04:00
3 changed files with 32 additions and 3 deletions

View File

@ -0,0 +1,28 @@
---
name: Submodules Sync
on:
push:
branches:
- master
jobs:
sync:
container:
image: focs.ji.sjtu.edu.cn:5000/gitea/runner-images:ubuntu-latest
volumes:
- /home/actions/.ssh:/root/.ssh
steps:
- name: Check out repository code
uses: https://gitea.com/BoYanZh/checkout@focs
- name: Git Submodule Update
run: |
git pull --recurse-submodules
git submodule update --remote --recursive
- name: Set up Git
run: |
git config --global user.name "gitea-actions[bot]"
git config --global user.email "gitea-actions[bot]@users.noreply.gitea.com"
chown -R root:root /root/.ssh
- name: Commit update
run: |
git commit -am "chore: update submodule references" && git push || echo "No changes to commit"

View File

@ -1,7 +1,7 @@
--- ---
repos: repos:
- repo: https://github.com/pre-commit/pre-commit-hooks - repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0 rev: v5.0.0
hooks: hooks:
- id: check-yaml - id: check-yaml
- id: end-of-file-fixer - id: end-of-file-fixer
@ -26,12 +26,12 @@ repos:
entry: make build entry: make build
language: system language: system
always_run: true always_run: true
stages: [commit] stages: [pre-commit]
pass_filenames: false pass_filenames: false
- id: make-test - id: make-test
name: make test name: make test
entry: make test entry: make test
language: system language: system
always_run: true always_run: true
stages: [commit] stages: [pre-commit]
pass_filenames: false pass_filenames: false

View File

@ -7,6 +7,7 @@
1. Make sure you are in a Unix-like OS (Linux, MacOS). For Windows, use [WSL 2](https://learn.microsoft.com/en-us/windows/wsl/install). 1. Make sure you are in a Unix-like OS (Linux, MacOS). For Windows, use [WSL 2](https://learn.microsoft.com/en-us/windows/wsl/install).
2. Install [Go](https://go.dev/doc/install). Also, make sure `make` and `git` are installed and all 3 programs are presented in `$PATH`. 2. Install [Go](https://go.dev/doc/install). Also, make sure `make` and `git` are installed and all 3 programs are presented in `$PATH`.
- If you have problem on connecting to the Go website and Go packages, download Go from [studygolang](https://studygolang.com/dl) and run `go env -w GOPROXY=https://goproxy.io,direct` to set the Go modules mirror proxy after installing Go.
3. Enable cgroup v2 for your OS. Check [here](https://stackoverflow.com/a/73376219/13724598). So that you do not need root permission to run `go-judge`. 3. Enable cgroup v2 for your OS. Check [here](https://stackoverflow.com/a/73376219/13724598). So that you do not need root permission to run `go-judge`.