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

Automated Release updates to homebrew bruno cask #105

Open
helloanoop opened this issue Feb 24, 2023 · 8 comments
Open

Automated Release updates to homebrew bruno cask #105

helloanoop opened this issue Feb 24, 2023 · 8 comments

Comments

@helloanoop
Copy link
Contributor

Bruno is available on homebrew. (See #32)

Creating this issue to investigate our options to automating hombrew updates for latest bruno releases

@helpermethod
Copy link

helpermethod commented Feb 27, 2023

I've seen that someone has already updated the Homebrew cask to 0.10.2 using brew bump-cask-pr.

So from my understanding, a GH workflow similar to this should be enough to automate the release process:

name: Bump Homebrew Cask
on:
  push:
    tags:
      - 'v[0-9]+\.[0-9]+\.[0-9]+'
jobs:
  bump:
    runs-on: macos-10.15
    steps:
      - name: Bump Homebrew Cask
         run: brew bump-cask-pr bruno --version "${GITHUB_REF_NAME#v}"    

The bump-cask-pr command should update the new checksums automatically, if I interpret this correctly 😆 .

Depending on how you release bruno, we may need to listen on another trigger:

on:
  release:
    types: [published]

@helloanoop
Copy link
Contributor Author

Thanks @helpermethod Let me try to set it up.

@helloanoop
Copy link
Contributor Author

@helpermethod
Copy link

Hi @helloanoop,

I'm currently short on time but will try to have a look at it ASAP.

@helpermethod
Copy link

helpermethod commented May 3, 2023

Hi @helloanoop , I'm gonna revisit the issue this week. From a quick look, it seems that the problem is that you need a token
with more rights as the default GH token.

This is from the doc of a bump-cask (I don't think we need a specialized action which just wraps bump-cask-pr btw):

One should use the Personal Access Token for token input to this Action, not the default GITHUB_TOKEN, because brew bump-cask-pr creates a fork of the cask's tap repository (if needed) and then creates a pull request.

And further down the line:

Required, custom GitHub access token with the 'public_repo' and 'workflow' scopes

I also found a good description of the necessary steps:

https://gist.github.com/willgarcia/7347306870779bfa664e

@leikoilja
Copy link

that would be amazing to be able to brew and then update the bruno using brew :)

@helpermethod
Copy link

@leikoilja It seems that some diligient user/contributor is already updating the brew cask manually, but an automatic process would obviously be better ;).

@leikoilja
Copy link

seems to be the case :)
i just installed bruno using homebrew and it brewed v0.16.5, which is not that far from the latest v0.17.0 that just got dropped 😅

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

No branches or pull requests

3 participants