Skip to content

Commit 3d68444

Browse files
make ci run in this fork (#9)
1 parent 92b3ece commit 3d68444

File tree

5 files changed

+30
-19
lines changed

5 files changed

+30
-19
lines changed

.github/actions/choco/entrypoint.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ rm -f act-cli.*.nupkg
2424
mkdir -p tools
2525
cp LICENSE tools/LICENSE.txt
2626
cp VERIFICATION tools/VERIFICATION.txt
27-
cp dist/act_windows_amd64_v1/act.exe tools/
27+
cp dist/act-cli_windows_amd64_v1/act-cli.exe tools/
2828
choco pack act-cli.nuspec --version ${VERSION}
2929
if [[ "$INPUT_PUSH" == "true" ]]; then
3030
choco push act-cli.${VERSION}.nupkg --api-key ${INPUT_APIKEY} -s https://push.chocolatey.org/ --timeout 180

.github/workflows/checks.yml

+13-13
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
version: v1.62
2828
- uses: megalinter/megalinter/flavors/[email protected]
2929
env:
30-
DEFAULT_BRANCH: master
30+
DEFAULT_BRANCH: ${{ github.event.repository.default_branch }}
3131
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3232
VALIDATE_ALL_CODEBASE: false
3333
GITHUB_STATUS_REPORTER: ${{ !env.ACT }}
@@ -117,73 +117,73 @@ jobs:
117117
uses: actions/upload-artifact@v4
118118
with:
119119
name: act-linux-amd64
120-
path: dist/act_linux_amd64_v1/act
120+
path: dist/act-cli_linux_amd64_v1/act-cli
121121
- name: Capture i386 (32-bit) Linux binary
122122
if: ${{ !env.ACT }}
123123
uses: actions/upload-artifact@v4
124124
with:
125125
name: act-linux-i386
126-
path: dist/act_linux_386/act
126+
path: dist/act-cli_linux_386/act-cli
127127
- name: Capture arm64 (64-bit) Linux binary
128128
if: ${{ !env.ACT }}
129129
uses: actions/upload-artifact@v4
130130
with:
131131
name: act-linux-arm64
132-
path: dist/act_linux_arm64/act
132+
path: dist/act-cli_linux_arm64/act-cli
133133
- name: Capture armv6 (32-bit) Linux binary
134134
if: ${{ !env.ACT }}
135135
uses: actions/upload-artifact@v4
136136
with:
137137
name: act-linux-armv6
138-
path: dist/act_linux_arm_6/act
138+
path: dist/act-cli_linux_arm_6/act-cli
139139
- name: Capture armv7 (32-bit) Linux binary
140140
if: ${{ !env.ACT }}
141141
uses: actions/upload-artifact@v4
142142
with:
143143
name: act-linux-armv7
144-
path: dist/act_linux_arm_7/act
144+
path: dist/act-cli_linux_arm_7/act-cli
145145
- name: Capture riscv64 (64-bit) Linux binary
146146
if: ${{ !env.ACT }}
147147
uses: actions/upload-artifact@v4
148148
with:
149149
name: act-linux-riscv64
150-
path: dist/act_linux_riscv64/act
150+
path: dist/act-cli_linux_riscv64/act-cli
151151
- name: Capture x86_64 (64-bit) Windows binary
152152
if: ${{ !env.ACT }}
153153
uses: actions/upload-artifact@v4
154154
with:
155155
name: act-windows-amd64
156-
path: dist/act_windows_amd64_v1/act.exe
156+
path: dist/act-cli_windows_amd64_v1/act-cli.exe
157157
- name: Capture i386 (32-bit) Windows binary
158158
if: ${{ !env.ACT }}
159159
uses: actions/upload-artifact@v4
160160
with:
161161
name: act-windows-i386
162-
path: dist/act_windows_386/act.exe
162+
path: dist/act-cli_windows_386/act-cli.exe
163163
- name: Capture arm64 (64-bit) Windows binary
164164
if: ${{ !env.ACT }}
165165
uses: actions/upload-artifact@v4
166166
with:
167167
name: act-windows-arm64
168-
path: dist/act_windows_arm64/act.exe
168+
path: dist/act-cli_windows_arm64/act-cli.exe
169169
- name: Capture armv7 (32-bit) Windows binary
170170
if: ${{ !env.ACT }}
171171
uses: actions/upload-artifact@v4
172172
with:
173173
name: act-windows-armv7
174-
path: dist/act_windows_arm_7/act.exe
174+
path: dist/act-cli_windows_arm_7/act-cli.exe
175175
- name: Capture x86_64 (64-bit) MacOS binary
176176
if: ${{ !env.ACT }}
177177
uses: actions/upload-artifact@v4
178178
with:
179179
name: act-macos-amd64
180-
path: dist/act_darwin_amd64_v1/act
180+
path: dist/act-cli_darwin_amd64_v1/act-cli
181181
- name: Capture arm64 (64-bit) MacOS binary
182182
if: ${{ !env.ACT }}
183183
uses: actions/upload-artifact@v4
184184
with:
185185
name: act-macos-arm64
186-
path: dist/act_darwin_arm64/act
186+
path: dist/act-cli_darwin_arm64/act-cli
187187
- name: Chocolatey
188188
uses: ./.github/actions/choco
189189
with:

.github/workflows/release.yml

+14-3
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ on:
66

77
jobs:
88
release:
9+
# TODO use environment to scope secrets
910
name: release
1011
runs-on: ubuntu-latest
1112
steps:
@@ -29,26 +30,33 @@ jobs:
2930
version: latest
3031
args: release --clean
3132
env:
32-
GITHUB_TOKEN: ${{ secrets.GORELEASER_GITHUB_TOKEN }}
33+
GITHUB_TOKEN: ${{ secrets.GORELEASER_GITHUB_TOKEN || github.token }}
3334
- name: Winget
3435
uses: vedantmgoyal2009/winget-releaser@v2
3536
with:
3637
identifier: nektos.act
3738
installers-regex: '_Windows_\w+\.zip$'
3839
token: ${{ secrets.WINGET_TOKEN }}
40+
if: env.ENABLED
41+
env:
42+
ENABLED: ${{ secrets.WINGET_TOKEN && '1' || '' }}
3943
- name: Chocolatey
4044
uses: ./.github/actions/choco
4145
with:
4246
version: ${{ github.ref }}
4347
apiKey: ${{ secrets.CHOCO_APIKEY }}
4448
push: true
49+
if: env.ENABLED
50+
env:
51+
ENABLED: ${{ secrets.CHOCO_APIKEY && '1' || '' }}
52+
# TODO use ssh deployment key
4553
- name: GitHub CLI extension
4654
uses: actions/github-script@v7
4755
with:
48-
github-token: ${{ secrets.GORELEASER_GITHUB_TOKEN }}
56+
github-token: ${{ secrets.CLI_GITHUB_TOKEN || secrets.GORELEASER_GITHUB_TOKEN }}
4957
script: |
5058
const mainRef = (await github.rest.git.getRef({
51-
owner: 'nektos',
59+
owner: context.repo.owner,
5260
repo: 'gh-act',
5361
ref: 'heads/main',
5462
})).data;
@@ -59,3 +67,6 @@ jobs:
5967
ref: context.ref,
6068
sha: mainRef.object.sha,
6169
});
70+
if: env.ENABLED
71+
env:
72+
ENABLED: ${{ (secrets.CLI_GITHUB_TOKEN || secrets.GORELEASER_GITHUB_TOKEN) && '1' || '' }}

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ Please look at the [act user guide](https://nektosact.com) for more documentatio
2727

2828
# Support
2929

30-
Need help? Ask on [Gitter](https://gitter.im/nektos/act)!
30+
Need help? Ask on [Discussions](https://github.com/actions-oss/act-cli/discussions)!
3131

3232
# Contributing
3333

pkg/runner/testdata/issue-1195/push.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ jobs:
1010
- name: print env.variable
1111
run: |
1212
echo ${{ env.variable }}
13-
exit ${{ (env.variable == 'nektos') && '0' || '1'}}
13+
exit ${{ (env.variable == 'actions-oss') && '0' || '1'}}

0 commit comments

Comments
 (0)