Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
193 views
in Technique[技术] by (71.8m points)

How to get taps to update when there is a new Homebrew release?

I currently have a private Homebrew Github repo with the following Formula for a private tool I made and use for myself:

require_relative "../custom_download_strategy.rb"

class MyTool < Formula
    desc "My Tool"
    homepage "https://github.com/<username>/homebrew-<pkg>"
    url "https://github.com/<username>/homebrew-<package>/releases/download/v0.1.3/pkg.tar.gz", :using => CustomGitHubPrivateRepositoryReleaseDownloadStrategy
    version "0.1.3"
    sha256 ""
end

Whenever I update my tool, I repackage my app and then edit the version number and URL of my Formula accordingly.

However, despite making these changes and pushing to the Github repo, when I run brew upgrade <my tool> on a machine I want to use the upgraded tool, Homebrew just spits out the following error:

Warning: v0.1.3 already installed

The only way I that I can download the new version of the tool is if I run the following:

brew untap <my tap>

brew tap <my tap>

brew install <my tool>

How can I configure my private repo so that if I want to upgrade my tool, I can simply run brew upgrade <my tool>?

question from:https://stackoverflow.com/questions/66057638/how-to-get-taps-to-update-when-there-is-a-new-homebrew-release

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

1.4m articles

1.4m replys

5 comments

57.0k users

...