Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(preview-comment): auto-fill the github token #156

Merged
merged 3 commits into from
Jan 25, 2022

Conversation

byCedric
Copy link
Member

@byCedric byCedric commented Jan 24, 2022

Linked issue

This change allows the preview-action to inehrit the token from the current run. It does that by setting a default value for github-token to ${{ github.token }}.

This would make it way easier to set previews up, by not thinking about that token at all. But, it's a bit more "intrusive" compared to the previous way.

@byCedric byCedric requested a review from jonsamp January 24, 2022 13:05
github-token:
description: GitHub access token to comment on PRs
required: false
default: ${{ github.token }}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is where the magic happens, it uses the github context to auto-fill the token on github-token.

@byCedric byCedric force-pushed the cedric/refactor/preview-token branch from d9d5d07 to e25237b Compare January 24, 2022 13:13
Copy link
Member

@jonsamp jonsamp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this makes things simpler so im a fan!

@byCedric byCedric merged commit 204dfed into main Jan 25, 2022
@byCedric byCedric deleted the cedric/refactor/preview-token branch January 25, 2022 16:47
github-actions bot pushed a commit that referenced this pull request Jan 25, 2022
### [7.0.2](7.0.1...7.0.2) (2022-01-25)

### Code changes

* **preview-comment:** auto-fill the github token ([#156](#156)) ([204dfed](204dfed))
@github-actions
Copy link

🎉 This PR is included in version 7.0.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants