Fix github action logic
rpdelaney opened this issue · 7 comments
Might be that it needs this, but I also have a similar workflow working without the token so I'm a bit confused.
It's already set by GitHub automatically https://docs.github.com/en/actions/security-guides/automatic-token-authentication#using-the-github_token-in-a-workflow
Could you try adding this to this section
LS_COLORS/.github/workflows/build.yml
Lines 18 to 25 in 572b294
env: GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
I might try testing this in a fork to avoid disruption downstream. I have a lot on my plate right now but hopefully I can get to it soon. The first task will be to reproduce the failure in a fork.
Another solution is to avoid all this logic to detect a merged PR, since there is no real official way to do it. And instead, run the action on push
but only on master
which will be triggered also when a PR is merged to master
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 8b4405e..f0f410d 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -1,12 +1,10 @@
name: 'Release'
on:
- pull_request:
+ push:
branches: [master]
- types: [closed]
jobs:
release:
- if: github.event.pull_request.merged == true
runs-on: ubuntu-latest
steps:
- name: 'Check out Git repository'
@ahmedelgabri I've been very busy with trying to close on a house. Would you be willing to send a pull request with the fix? I just have not been able to make time. :(
@rpdelaney can you have a look at #186?
Did that work?
Edit: seems like lscolors.sh
wasn't rebuilt
@rpdelaney that's because the only change that happened to the source code was #183 which generated a correct .csh
file. The .sh
files didn't change, so only .csh
was rebuilt.