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

browserpass: bump to 3.1.0 #26

Merged
merged 2 commits into from
Nov 7, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 9 additions & 19 deletions Formula/browserpass.rb
Original file line number Diff line number Diff line change
@@ -1,14 +1,8 @@
class Browserpass < Formula

Check failure on line 1 in Formula/browserpass.rb

View workflow job for this annotation

GitHub Actions / pr-pull

Can't find dependency '"coreutils"'.

Check failure on line 1 in Formula/browserpass.rb

View workflow job for this annotation

GitHub Actions / pr-pull

Can't find dependency '"gnu-sed"'.

Check failure on line 1 in Formula/browserpass.rb

View workflow job for this annotation

GitHub Actions / pr-pull

Can't find dependency '"go"'.

Check failure on line 1 in Formula/browserpass.rb

View workflow job for this annotation

GitHub Actions / pr-pull

Can't find dependency '"gpg"'.

Check failure on line 1 in Formula/browserpass.rb

View workflow job for this annotation

GitHub Actions / pr-pull

Can't find dependency '"pinentry"'.
desc "Host application for browser extension providing access to your password store"
homepage "https://github.com/browserpass/browserpass-native"

if Hardware::CPU.arm?
url "https://github.com/browserpass/browserpass-native/releases/download/3.0.8/browserpass-darwin-arm64-3.0.8.tar.gz"
sha256 "f0a21c7610fb9c68a2f1b8aa8c4116678a2318e61b0b60067d79b5b23bcd4502"
else
url "https://github.com/browserpass/browserpass-native/releases/download/3.0.8/browserpass-darwin64-3.0.8.tar.gz"
sha256 "a4bd59a0d2fe74dfb16cca8d47011415eaa19d5da39a8c60ac948a491cfa7214"
end
url "https://github.com/browserpass/browserpass-native/archive/refs/tags/3.1.0.tar.gz"
sha256 "df90e9a02faa0081fe8bce78a8ecef1e4394f642955f18f452ee0079be85816e"

bottle do
root_url "https://github.com/Amar1729/homebrew-formulae/releases/download/browserpass-3.0.8"
Expand All @@ -17,9 +11,13 @@

depends_on "coreutils" => :build
depends_on "gnu-sed" => :build
depends_on "go" => :build
depends_on "gpg"
depends_on "pinentry"
depends_on "pinentry-mac"

on_macos do
depends_on "pinentry-mac"
end

resource "testfile" do
url "https://github.com/browserpass/browserpass-native/files/3062744/request.hex.txt"
Expand All @@ -30,12 +28,8 @@
ENV["DESTDIR"] = ""
ENV["PREFIX"] = prefix.to_s

if Hardware::CPU.arm?
inreplace "Makefile", "BIN ?= browserpass", "BIN ?= browserpass-darwin-arm64"
else
inreplace "Makefile", "BIN ?= browserpass", "BIN ?= browserpass-darwin64"
end
system "make", "configure"
system "make"
system "make", "install"

# NOT possible to symlink the hosts files from a homebrew formula, since they go under HOME
Expand All @@ -55,14 +49,10 @@
EOF
end

test do

Check warning on line 52 in Formula/browserpass.rb

View workflow job for this annotation

GitHub Actions / test-bot (ubuntu-latest)

`brew test --verbose amar1729/formulae/browserpass` failed on Linux!

/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/bin/bundle clean Error: No available formula with the name "coreutils".
resource("testfile").stage(testpath)
# fails with 14: $HOME/.password-store doesn't exist, since homebrew uses its own $HOME
# a return value other than 14 is incorrect here
if Hardware::CPU.arm?
shell_output("#{prefix}/bin/browserpass-darwin-arm64 < #{testpath}/request.hex.txt 2>/dev/null", 14)
else
shell_output("#{prefix}/bin/browserpass-darwin64 < #{testpath}/request.hex.txt 2>/dev/null", 14)
end
shell_output("#{prefix}/bin/browserpass < #{testpath}/request.hex.txt 2>/dev/null", 14)
end
end
Loading