File tree 2 files changed +43
-8
lines changed
2 files changed +43
-8
lines changed Original file line number Diff line number Diff line change
1
+ name : " Install p2pd"
2
+ inputs :
3
+ os :
4
+ required : true
5
+ cpu :
6
+ required : true
7
+
8
+ runs :
9
+ using : " composite"
10
+ steps :
11
+ - name : Download p2pd
12
+ shell : bash
13
+ run : |
14
+ mkdir -p .ci-bin
15
+
16
+ if [[ "${{ inputs.os }}" == windows* ]]; then
17
+ curl -sLO "https://github.com/libp2p/go-libp2p-daemon/releases/download/v0.9.1/p2pd-windows-amd64.exe"
18
+ mv p2pd-windows-amd64.exe .ci-bin/p2pd.exe
19
+ elif [[ "${{ inputs.os }}" == macos* ]]; then
20
+ if [ "${{ inputs.cpu }}" = "arm64" ]; then
21
+ curl -sLO "https://github.com/libp2p/go-libp2p-daemon/releases/download/v0.9.1/p2pd-darwin-arm64"
22
+ mv p2pd-darwin-arm64 .ci-bin/p2pd
23
+ else
24
+ curl -sLO "https://github.com/libp2p/go-libp2p-daemon/releases/download/v0.9.1/p2pd-darwin-amd64"
25
+ mv p2pd-darwin-amd64 .ci-bin/p2pd
26
+ fi
27
+ chmod +x .ci-bin/p2pd
28
+ else
29
+ if [ "${{ inputs.cpu }}" = "i386" ]; then
30
+ echo "No official i386 build available for p2pd. Exiting..."
31
+ exit 1
32
+ else
33
+ curl -sLO "https://github.com/libp2p/go-libp2p-daemon/releases/download/v0.9.1/p2pd-linux-amd64"
34
+ mv p2pd-linux-amd64 .ci-bin/p2pd
35
+ chmod +x .ci-bin/p2pd
36
+ fi
37
+ fi
38
+
39
+ echo "${PWD}/.ci-bin" >> $GITHUB_PATH
Original file line number Diff line number Diff line change 21
21
platform :
22
22
- os : linux
23
23
cpu : amd64
24
- - os : linux
25
- cpu : i386
26
24
- os : linux-gcc-14
27
25
cpu : amd64
28
26
- os : macos
@@ -78,14 +76,12 @@ jobs:
78
76
shell : ${{ matrix.shell }}
79
77
nim_ref : ${{ matrix.nim.ref }}
80
78
81
- - name : Setup Go
82
- uses : actions/setup-go@v5
83
- with :
84
- go-version : ' ~1.16.0' # That's the minimum Go version that works with arm.
85
79
86
80
- name : Install p2pd
87
- run : |
88
- V=1 bash scripts/build_p2pd.sh p2pdCache 124530a3
81
+ uses : ./.github/actions/install_p2pd
82
+ with :
83
+ os : ${{ matrix.platform.os }}
84
+ cpu : ${{ matrix.platform.cpu }}
89
85
90
86
- name : Restore deps from cache
91
87
id : deps-cache
You can’t perform that action at this time.
0 commit comments