Skip to content

Commit 62f7ce2

Browse files
authored
sync: update CI config files (#31)
1 parent b33a1a0 commit 62f7ce2

File tree

4 files changed

+62
-54
lines changed

4 files changed

+62
-54
lines changed

Diff for: .github/workflows/automerge.yml

+4-46
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,11 @@
11
# File managed by web3-bot. DO NOT EDIT.
22
# See https://github.com/protocol/.github/ for details.
33

4-
# Automatically merge pull requests opened by web3-bot, as soon as (and only if) all tests pass.
5-
# This reduces the friction associated with updating with our workflows.
6-
7-
on: [ pull_request ]
84
name: Automerge
5+
on: [ pull_request ]
96

107
jobs:
11-
automerge-check:
12-
if: github.event.pull_request.user.login == 'web3-bot'
13-
runs-on: ubuntu-latest
14-
outputs:
15-
status: ${{ steps.should-automerge.outputs.status }}
16-
steps:
17-
- uses: actions/checkout@v2
18-
with:
19-
fetch-depth: 0
20-
- name: Check if we should automerge
21-
id: should-automerge
22-
run: |
23-
for commit in $(git rev-list --first-parent origin/${{ github.event.pull_request.base.ref }}..${{ github.event.pull_request.head.sha }}); do
24-
committer=$(git show --format=$'%ce' -s $commit)
25-
echo "Committer: $committer"
26-
if [[ "$committer" != "[email protected]" ]]; then
27-
echo "Commit $commit wasn't committed by web3-bot, but by $committer."
28-
echo "::set-output name=status::false"
29-
exit
30-
fi
31-
done
32-
echo "::set-output name=status::true"
338
automerge:
34-
needs: automerge-check
35-
runs-on: ubuntu-latest
36-
# The check for the user is redundant here, as this job depends on the automerge-check job,
37-
# but it prevents this job from spinning up, just to be skipped shortly after.
38-
if: github.event.pull_request.user.login == 'web3-bot' && needs.automerge-check.outputs.status == 'true'
39-
steps:
40-
- name: Wait on tests
41-
uses: lewagon/wait-on-check-action@bafe56a6863672c681c3cf671f5e10b20abf2eaa # v0.2
42-
with:
43-
ref: ${{ github.event.pull_request.head.sha }}
44-
repo-token: ${{ secrets.GITHUB_TOKEN }}
45-
wait-interval: 10
46-
running-workflow-name: 'automerge' # the name of this job
47-
- name: Merge PR
48-
uses: pascalgn/automerge-action@741c311a47881be9625932b0a0de1b0937aab1ae # v0.13.1
49-
env:
50-
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
51-
MERGE_LABELS: ""
52-
MERGE_METHOD: "squash"
53-
MERGE_DELETE_BRANCH: true
9+
uses: protocol/.github/.github/workflows/automerge.yml@master
10+
with:
11+
job: 'automerge'

Diff for: .github/workflows/go-check.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
submodules: recursive
1717
- uses: actions/setup-go@v2
1818
with:
19-
go-version: "1.17.x"
19+
go-version: "1.18.x"
2020
- name: Run repo-specific setup
2121
uses: ./.github/actions/go-check-setup
2222
if: hashFiles('./.github/actions/go-check-setup') != ''
@@ -27,7 +27,7 @@ jobs:
2727
echo "RUNGOGENERATE=true" >> $GITHUB_ENV
2828
fi
2929
- name: Install staticcheck
30-
run: go install honnef.co/go/tools/cmd/staticcheck@c8caa92bad8c27ae734c6725b8a04932d54a147b # 2021.1.2 (v0.2.2)
30+
run: go install honnef.co/go/tools/cmd/staticcheck@d7e217c1ff411395475b2971c0824e1e7cc1af98 # 2022.1 (v0.3.0)
3131
- name: Check that go.mod is tidy
3232
uses: protocol/[email protected]
3333
with:
@@ -71,4 +71,3 @@ jobs:
7171
git status --short
7272
exit 1
7373
fi
74-

Diff for: .github/workflows/go-test.yml

+6-4
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ jobs:
1010
fail-fast: false
1111
matrix:
1212
os: [ "ubuntu", "windows", "macos" ]
13-
go: [ "1.16.x", "1.17.x" ]
13+
go: [ "1.17.x", "1.18.x" ]
1414
env:
1515
COVERAGES: ""
16-
runs-on: ${{ matrix.os }}-latest
17-
name: ${{ matrix.os}} (go ${{ matrix.go }})
16+
runs-on: ${{ format('{0}-latest', matrix.os) }}
17+
name: ${{ matrix.os }} (go ${{ matrix.go }})
1818
steps:
1919
- uses: actions/checkout@v2
2020
with:
@@ -50,7 +50,9 @@ jobs:
5050
env:
5151
GOARCH: 386
5252
with:
53-
run: go test -v ./...
53+
run: |
54+
export "PATH=${{ env.PATH_386 }}:$PATH"
55+
go test -v ./...
5456
- name: Run tests with race detector
5557
if: ${{ matrix.os == 'ubuntu' }} # speed things up. Windows and OSX VMs are slow
5658
uses: protocol/[email protected]

Diff for: go.mod

+50-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/ipfs/go-unixfsnode
22

3-
go 1.16
3+
go 1.17
44

55
require (
66
github.com/Stebalien/go-bitfield v0.0.1
@@ -20,3 +20,52 @@ require (
2020
github.com/stretchr/testify v1.7.0
2121
google.golang.org/protobuf v1.27.1
2222
)
23+
24+
require (
25+
github.com/davecgh/go-spew v1.1.1 // indirect
26+
github.com/gogo/protobuf v1.3.2 // indirect
27+
github.com/google/uuid v1.2.0 // indirect
28+
github.com/hashicorp/golang-lru v0.5.4 // indirect
29+
github.com/ipfs/bbloom v0.0.4 // indirect
30+
github.com/ipfs/go-block-format v0.0.3 // indirect
31+
github.com/ipfs/go-blockservice v0.2.1 // indirect
32+
github.com/ipfs/go-datastore v0.5.0 // indirect
33+
github.com/ipfs/go-ipfs-blockstore v1.1.2 // indirect
34+
github.com/ipfs/go-ipfs-ds-help v1.1.0 // indirect
35+
github.com/ipfs/go-ipfs-exchange-interface v0.1.0 // indirect
36+
github.com/ipfs/go-ipfs-exchange-offline v0.1.1 // indirect
37+
github.com/ipfs/go-ipld-cbor v0.0.5 // indirect
38+
github.com/ipfs/go-ipld-legacy v0.1.0 // indirect
39+
github.com/ipfs/go-log v1.0.5 // indirect
40+
github.com/ipfs/go-log/v2 v2.3.0 // indirect
41+
github.com/ipfs/go-metrics-interface v0.0.1 // indirect
42+
github.com/ipfs/go-verifcid v0.0.1 // indirect
43+
github.com/jbenet/goprocess v0.1.4 // indirect
44+
github.com/klauspost/cpuid/v2 v2.0.9 // indirect
45+
github.com/libp2p/go-buffer-pool v0.0.2 // indirect
46+
github.com/mattn/go-isatty v0.0.13 // indirect
47+
github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1 // indirect
48+
github.com/minio/sha256-simd v1.0.0 // indirect
49+
github.com/mr-tron/base58 v1.2.0 // indirect
50+
github.com/multiformats/go-base32 v0.0.3 // indirect
51+
github.com/multiformats/go-base36 v0.1.0 // indirect
52+
github.com/multiformats/go-multibase v0.0.3 // indirect
53+
github.com/multiformats/go-varint v0.0.6 // indirect
54+
github.com/opentracing/opentracing-go v1.2.0 // indirect
55+
github.com/petar/GoLLRB v0.0.0-20210522233825-ae3b015fd3e9 // indirect
56+
github.com/pmezard/go-difflib v1.0.0 // indirect
57+
github.com/polydawn/refmt v0.0.0-20201211092308-30ac6d18308e // indirect
58+
github.com/whyrusleeping/cbor v0.0.0-20171005072247-63513f603b11 // indirect
59+
github.com/whyrusleeping/cbor-gen v0.0.0-20200123233031-1cdf64d27158 // indirect
60+
github.com/whyrusleeping/chunker v0.0.0-20181014151217-fe64bd25879f // indirect
61+
go.uber.org/atomic v1.7.0 // indirect
62+
go.uber.org/multierr v1.7.0 // indirect
63+
go.uber.org/zap v1.16.0 // indirect
64+
golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97 // indirect
65+
golang.org/x/exp v0.0.0-20210615023648-acb5c1269671 // indirect
66+
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect
67+
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c // indirect
68+
golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect
69+
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
70+
lukechampine.com/blake3 v1.1.6 // indirect
71+
)

0 commit comments

Comments
 (0)