File tree 5 files changed +28
-21
lines changed
5 files changed +28
-21
lines changed Original file line number Diff line number Diff line change 4
4
schedule :
5
5
- cron : ' 30 0 * * *'
6
6
# - cron: '*/5 * * * *'
7
+
7
8
jobs :
8
9
build :
9
10
runs-on : ubuntu-latest
10
11
name : run
11
12
steps :
12
- - uses : actions/checkout@v2
13
+ - name : Checkout
14
+ uses : actions/checkout@v3
13
15
with :
14
16
ref : ' gh-pages'
15
17
16
- - name : Golang Action
17
- uses :
cedrickring/[email protected]
18
-
18
+ - name : Setup Golang
19
+ uses : actions/setup-go@v4
20
+ with :
21
+ go-version-file : ' go.mod'
22
+
23
+ - name : Update redirects
24
+ run : make
25
+
19
26
- name : Commit files
20
27
run : |
21
28
git config --local user.email "[email protected] "
22
29
git config --local user.name "GitHub Action"
23
30
git add --update
24
31
if ! git diff --quiet HEAD ; then
25
32
DATE=$(date "+%Y/%m/%d %H:%M %Z")
26
- git commit -m "Updated by GithubActions at ${DATE}"
27
- git push
33
+ git commit -m "Updated by GithubActions at ${DATE}"
34
+ git push
28
35
fi
29
-
30
- # - name: Push changes
31
- # uses: ad-m/github-push-action@master
32
- # with:
33
- # github_token: ${{ secrets.GITHUB_TOKEN }}
34
- # branch: 'gh-pages'
Original file line number Diff line number Diff line change 1
1
run :
2
- go get -u github.com/koron/go-github
3
- go get -u gopkg.in/yaml.v2
4
2
go run _scripts/vim_jp-redirects-update/main.go
Original file line number Diff line number Diff line change 5
5
### Pre requirements
6
6
7
7
* of course checkout this [ vim-jp/redirects] [ 1 ] repo
8
- * [ go 1.5.3 or above (1.6 is recommended)] [ 2 ]
9
- * golang external packages
10
-
11
- ```
12
- $ go get -u github.com/koron/go-github
13
- $ go get -u gopkg.in/yaml.v2
14
- ```
8
+ * [ go 1.16 or above] [ 2 ]
15
9
16
10
### Update redirects
17
11
Original file line number Diff line number Diff line change
1
+ module github.com/vim-jp/redirects
2
+
3
+ go 1.16
4
+
5
+ require (
6
+ github.com/koron/go-github v0.0.0-20160618135937-92fbbed2e046
7
+ gopkg.in/yaml.v2 v2.4.0
8
+ )
Original file line number Diff line number Diff line change
1
+ github.com/koron/go-github v0.0.0-20160618135937-92fbbed2e046 h1:YjgY0oqB2nqyVckaRdLhOGslSgcsy0+DlSczAZpPPlM =
2
+ github.com/koron/go-github v0.0.0-20160618135937-92fbbed2e046 /go.mod h1:14+A+rOS/yG6PtS3DKcRYYM9tP0+zVghPxIzqOYBXks =
3
+ gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM =
4
+ gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 /go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0 =
5
+ gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY =
6
+ gopkg.in/yaml.v2 v2.4.0 /go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ =
You can’t perform that action at this time.
0 commit comments