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

STABLE_ASSET_URL and STABLE_ASSET_SHA256 not working #112

Open
shreddedbacon opened this issue Dec 3, 2019 · 5 comments
Open

STABLE_ASSET_URL and STABLE_ASSET_SHA256 not working #112

shreddedbacon opened this issue Dec 3, 2019 · 5 comments

Comments

@shreddedbacon
Copy link

I'm trying to configure tap-release and when I publish a release, tap-release updates the file successfully but it doesn't replace the STABLE_ASSET_URL or STABLE_ASSET_SHA256.

url: "https://github.com/amazeeio/lagoon-cli/releases/download/$STABLE_VERSION/lagoon-cli-${STABLE_VERSION}-darwin-amd64.tar.gz"
tap: amazeeio/homebrew-lagoon-cli/lagoon.rb
template: >
  class Lagoon < Formula
    desc     "Command line tool for interacting with a Lagoon API"
    homepage "https://github.com/amazeeio/lagoon-cli"
    version  "$STABLE_VERSION"
    url      "$STABLE_ASSET_URL"
    sha256   "$STABLE_ASSET_SHA256"

    bottle :unneeded

    def install
      bin.install "lagoon"
    end
  end

It manages to update the STABLE_VERSION fine once it makes its way in fine but the others do not.

class Lagoon < Formula
  desc     "Command line tool for interacting with a Lagoon API"
  homepage "https://github.com/amazeeio/lagoon-cli"
  version  "0.5.2"
  url      "$STABLE_ASSET_URL"
  sha256   "$STABLE_ASSET_SHA256"

  bottle :unneeded

  def install
    bin.install "lagoon"
  end
end

Any ideas?

@shreddedbacon
Copy link
Author

After reading the build kite tap-release https://github.com/buildkite/cli/blob/master/.github/tap-release.yml and seeing the tap https://github.com/buildkite/homebrew-cli/blob/master/bk.rb

It seems that STABLE_ASSET_URL and STABLE_ASSET_SHA256 aren't actually supported, and the readme is out of date?

@shreddedbacon
Copy link
Author

I've managed to get this working after using the buildkite files as examples.

@rogerluan
Copy link

I've managed to get this working after using the buildkite files as examples.

@shreddedbacon can you give more info on this? Were you able to use those 2 variables to release a tap of your own?

@shreddedbacon
Copy link
Author

I've managed to get this working after using the buildkite files as examples.

@shreddedbacon can you give more info on this? Were you able to use those 2 variables to release a tap of your own?

@rogerluan sorry. What were using for tap-releases have been broken for some time now and I haven't had time to look in to why they are broken. This is what our tap-release.yml file looked like though before it was broken. Hope it helps.

asset: "tool-$VERSION_NUMBER-darwin-amd64.tar.gz"
tap: "shreddedbacon/homebrew-tool/tool.rb"
template: >
  class Lagoon < Formula
    desc     "Generic Tool"
    homepage "https://github.com/shreddedbacon/tool"
    version  "$STABLE_VERSION"
    url      "$STABLE_URL"
    sha256   "$STABLE_SHA256"
    bottle :unneeded
    def install
      bin.install "tool"
    end
  end

@rogerluan
Copy link

All good, thanks for sharing @shreddedbacon ! 💪

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

2 participants