install: simplify brew setup

This commit is contained in:
Charles Gould 2024-08-26 10:56:00 -05:00
parent afc3da6fc9
commit 8f1bdf3c01
4 changed files with 8 additions and 134 deletions

View File

@ -1,3 +0,0 @@
docker
font-source-code-pro
minikube

View File

@ -1,84 +0,0 @@
ansifilter
assh
bandwhich
bash
cheat
cowsay
ctop
deno
diskus
dive
dos2unix
dungeon
dust
elvish
exa
fortune
fzy
gawk
gcc
git
git-filter-repo
gitui
gitup
go
grex
grpc
grpcui
grpcurl
gnu-sed
h2o
handbrake
haskell-stack
hexyl
htop
httpie
imagemagick
ipcalc
jq
kakoune
kubernetes-cli
lazydocker
lazygit
lighttpd
mdbook
micro
mill
mitmproxy
most
navi
nginx
nim
nushell
pianobar
pipx
procs
protobuf
prototool
pssh
pup
python
rustup-init
scour
screen
sd
solarus
sphinx-doc
spotify-tui
stormssh
suricata
svg2png
svgo
syncthing
tealdeer
telnet
tig
tldr
triangle
ttyd
ttyrec
watch
wget
yq
zeek
zoxide

View File

@ -1,44 +0,0 @@
#!/usr/bin/env fish
# TODO: how to handle other taps (especially an issue for casks)
function _install_extra_brews --argument-names favorite_brews
set --local brew_pkgs_installed (brew list --formula -1)
set --local brew_pkgs_options
for brew_pkg in (cat $favorite_brews)
if not contains -- $brew_pkg $brew_pkgs_installed
set -a brew_pkgs_options $brew_pkg
end
end
set --local brew_pkgs_inst (string split ' ' -- $brew_pkgs_options | eval "fzf --multi --prompt='[brew:install] '")
if test (count $brew_pkgs_inst) -gt 0
echo "Installing: $brew_pkgs_inst"
brew install $brew_pkgs_inst
end
end
function _install_extra_casks --argument-names favorite_casks
set --local brew_casks_installed (brew list --cask -1)
set --local brew_casks_options
for brew_cask in (cat $favorite_casks)
if not contains -- $brew_cask $brew_casks_installed
set -a brew_casks_options $brew_cask
end
end
set --local brew_casks_inst (string split ' ' -- $brew_casks_options | eval "fzf --multi --prompt='[brew:install] '")
if test (count $brew_casks_inst) -gt 0
echo "Installing: $brew_casks_inst"
brew cask install $brew_casks_inst
end
end
set --local script_dir (dirname (status -f))
if contains -- '--casks' $argv
_install_extra_casks (string join '/' -- $script_dir 'homebrew-casks.txt')
else
_install_extra_brews (string join '/' -- $script_dir 'homebrew-formulas.txt')
end
functions --erase _install_extra_brews
functions --erase _install_extra_casks

View File

@ -8,20 +8,25 @@ ROOTDIR=$(cd "$(dirname "$0")/.." && pwd)
brew install \
atuin \
bat \
direnv \
duf \
dust \
fd \
fish \
fzf \
git \
gitup \
git-delta \
git-interactive-rebase-tool \
helix \
jq \
just \
less \
macchina \
ripgrep \
tldr \
tree \
yq \
zoxide
# Install optional tools (prompted by fzf)
"$ROOTDIR/install/install-brew-extra.fish"
echo