Conversation
Adds the github token as env var for the run.sh script
|
closes #62 |
|
Hmm, does this override the custom GITHUB_TOKEN set in the action? If so, that's kinda bad. What I mean is: - name: Generate a changelog
uses: orhun/git-cliff-action@v4
env:
GITHUB_TOKEN: <custom-token>in that case, which GITHUB_TOKEN is being used? |
| shell: bash | ||
| run: ${GITHUB_ACTION_PATH}/run.sh --config=${{ inputs.config }} ${{ inputs.args }} | ||
| env: | ||
| GITHUB_TOKEN: ${{ env.GITHUB_TOKEN || inputs.github_token }} |
There was a problem hiding this comment.
Good point.
I’m not an expert in composite actions, and the docs are a bit vague on this subject.
But if they work like regular workflows, adding env.GITHUB_TOKEN || would make the env var on the ‘action’ step to use the env var of the ‘job’ step if supplied. Or use the input token if empty.
|
I think the new changes should give the appropriate behavior. |
|
@orhun have you had time to check my latest changes? |
orhun
left a comment
There was a problem hiding this comment.
Sorry for the delay, yeah, I'm counting on common sense and it should work as expected now.
Thanks for the PR!
|
No Pb, I was on vacation 😄 When can we expect the new release? |
|
Hopefully soon. I usually do it after I create a new release of |
Adds the github token as env var for the run.sh script