Skip to content

Instantly share code, notes, and snippets.

View Rahul-fix's full-sized avatar

Rahul Rahul-fix

View GitHub Profile
@sankalp-khare
sankalp-khare / switch-gnupg.sh
Created July 3, 2023 11:00
Downgrade / switch gnupg version in homebrew and pin it
#!/bin/bash -e
#-------------------------------------------------------------------------------------
# Summary: Executes commands to...
# * Check/output currently installed version of gnupg
# * Change into the brew repo/install directory
# * Find the git commit-id of the specified version of gnupg
# * git branch/switch to the commit-id
# * replace the brew installed version with the specified version (and pin it)
# * clean up the branch, switch back to master, and remove cached files
# * Check/output the newly installed version of gnupg