Skip to content

Commit

Permalink
gcm cask: Add arm64 support
Browse files Browse the repository at this point in the history
Update git-credential-manager-core cask to determine whether to install
the x64 pkg or the arm64 pkg based on the user's CPU.
  • Loading branch information
ldennington committed Jul 20, 2022
1 parent cba52bc commit 74bb6aa
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions Casks/git-credential-manager-core.rb
Original file line number Diff line number Diff line change
@@ -1,13 +1,18 @@
cask 'git-credential-manager-core' do
arch = Hardware::CPU.intel? ? "x64" : "arm64"
name 'Git Credential Manager'
homepage 'https://aka.ms/gcm'

version "2.0.785"
sha256 '064f8422122d84577b1dcd7845c942ad78aa899190fa5b5811a96528d1e89896'
if Hardware::CPU.intel?
sha256 '064f8422122d84577b1dcd7845c942ad78aa899190fa5b5811a96528d1e89896'
else
sha256 'fcbad7768f97cbff58a594c926b1db74472da676ddda569076d2f20fc4d55575'
end

url "https://github.com/GitCredentialManager/git-credential-manager/releases/download/v#{version.major_minor_patch}/gcm-osx-x64-#{version.major_minor_patch}.pkg"
url "https://github.com/GitCredentialManager/git-credential-manager/releases/download/v#{version.major_minor_patch}/gcm-osx-#{arch}-#{version.major_minor_patch}.pkg"

pkg "gcm-osx-x64-#{version}.pkg", allow_untrusted: true
pkg "gcm-osx-#{arch}-#{version}.pkg", allow_untrusted: true

uninstall script: {
executable: '/usr/local/share/gcm-core/uninstall.sh',
Expand Down

0 comments on commit 74bb6aa

Please sign in to comment.