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

Add new workflow to update homebrew formula on release #341

Merged
merged 3 commits into from
Feb 2, 2024

Conversation

cjappl
Copy link
Collaborator

@cjappl cjappl commented Feb 1, 2024

This workflow was found here:

https://github.com/dawidd6/action-homebrew-bump-formula

This should be very similar to our AUR workflow, which can be seen here:

name: AUR
on:
workflow_run:
workflows:
- "Release"
types:
- completed
jobs:
aur:
runs-on: ubuntu-latest
steps:
- name: Publish
uses: zokugun/github-actions-aur-releaser@v1
with:
package_name: forgit
aur_private_key: ${{ secrets.AUR_PRIVATE_KEY }}
aur_username: ${{ secrets.AUR_USERNAME }}
aur_email: ${{ secrets.AUR_EMAIL }}

I am writing an email to @wfxr asking him to add a BREW_TOKEN to our secrets with the appropriate permissions so this can run :). This change should not be submitted until he has confirmed the BREW_TOKEN has been added to our secrets.

Copy link
Collaborator

@carlfriedrich carlfriedrich left a comment

Choose a reason for hiding this comment

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

@cjappl Great stuff, thanks for checking this out!

.github/workflows/brew.yaml Outdated Show resolved Hide resolved
.github/workflows/brew.yaml Outdated Show resolved Hide resolved
@carlfriedrich
Copy link
Collaborator

@cjappl Thanks for the quick fixes.
Just being curious: did you generate a personal access token in your account for this purpose, so that the automatic brew commits will be done in your name?

@cjappl
Copy link
Collaborator Author

cjappl commented Feb 1, 2024

@cjappl Thanks for the quick fixes. Just being curious: did you generate a personal access token in your account for this purpose, so that the automatic brew commits will be done in your name?

No, I could, but it's probably safer from a security side to have wfxr do it (just so I don't have to send one of my tokens in plaintext to him via email or similar). He is still the one that must update any secrets or other Settings of this project, as it's under his name.

I would expect the commits likely end up under his user account in that case!

Copy link
Owner

@wfxr wfxr left a comment

Choose a reason for hiding this comment

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

LGTM.

@cjappl BREW_TOKEN has been set.

@cjappl
Copy link
Collaborator Author

cjappl commented Feb 2, 2024

Thanks @wfxr ! Will merge sometime tomorrow.

@cjappl cjappl merged commit 091d2f7 into FixZshCompletions Feb 2, 2024
7 checks passed
@cjappl cjappl deleted the NewBrewUpdateWorkflow branch February 2, 2024 18:28
@carlfriedrich
Copy link
Collaborator

@cjappl Did you merge into FixZshCompletions on purpose?

@cjappl
Copy link
Collaborator Author

cjappl commented Feb 2, 2024

Whoa. No I did not. Thank you for catching..... Let me fix that

@cjappl cjappl restored the NewBrewUpdateWorkflow branch February 2, 2024 19:37
cjappl added a commit that referenced this pull request Feb 2, 2024
* Add new homebrew workflow

* Review comments

* Review comments
cjappl added a commit that referenced this pull request Feb 2, 2024
@cjappl
Copy link
Collaborator Author

cjappl commented Feb 2, 2024

Great catch @carlfriedrich . would you please review #342 and #340 to make sure they are both as you expect them to be?

@cjappl cjappl deleted the NewBrewUpdateWorkflow branch February 2, 2024 19:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants