feat(mise/tools): install Ruby gems with mise

Also remove various old defunct install_*_global_packages helper shell commands.
This commit is contained in:
2025-05-04 10:22:59 +01:00
parent 1f61ddd8e4
commit 9760c4a2aa
5 changed files with 17 additions and 91 deletions

View File

@@ -33,6 +33,19 @@ ruby_install = true
"cargo:eza" = "latest"
"cargo:kubectl-watch" = "latest"
"cargo:paper-terminal" = "latest"
"gem:dotenv" = "latest"
"gem:erb_lint" = "latest"
"gem:foreman" = "latest"
"gem:reek" = "latest"
"gem:rubocop" = "latest"
"gem:ruby-lsp" = "latest"
"gem:ruby-lsp-rails" = "latest"
"gem:solargraph" = "latest"
"gem:solargraph-rails" = "latest"
"gem:syntax_tree" = "latest"
"gem:syntax_tree-haml" = "latest"
"gem:syntax_tree-rbs" = "latest"
"gem:yard" = "latest"
"go:github.com/rakyll/hey" = "latest"
"go:google.golang.org/grpc/cmd/protoc-gen-go-grpc" = "latest"
"go:google.golang.org/protobuf/cmd/protoc-gen-go" = "latest"
@@ -118,7 +131,7 @@ rclone = "latest"
restish = "latest"
ripgrep = "latest"
ruby = "latest"
rust = "latest"
rust = { version = "latest", components = "rust-analyzer,rust-src" }
sccache = "latest"
shellcheck = "latest"
shfmt = "latest"

View File

@@ -1,17 +1,3 @@
#
# Node.js environment setup.
#
# ==============================================================================
# global node packages
# ==============================================================================
install_node_global_packages() {
local npm_packages=(
)
npm install -g "${npm_packages[@]}"
# Ensure yarn and pnpm are enabled.
corepack enable
}

View File

@@ -9,21 +9,3 @@
alias ap="env OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES ansible-playbook"
alias av="env OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES ansible-vault"
alias mo="env OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES molecule"
# ==============================================================================
# global python package
# ==============================================================================
install_python_global_packages() {
local packages=(
'passlib'
)
local pipcmd="pip"
if ! command-exists pip && command-exists pip3; then
pipcmd="pip3"
fi
"$pipcmd" install --upgrade setuptools
"$pipcmd" install --upgrade "${packages[@]}"
}

View File

@@ -39,33 +39,3 @@ alias he="heroku"
alias f="foreman"
alias fs="foreman start"
alias fr="foreman run"
# ==============================================================================
# global ruby packages
# ==============================================================================
install_ruby_global_packages() {
local packages=(
'bundler:~> 1.0'
'bundler:~> 2.0'
bundler-audit
dotenv
erb_lint
foreman
method_source
pry-doc
reek
rubocop
ruby-lsp
ruby-lsp-rails
solargraph
solargraph-rails
steep
syntax_tree
syntax_tree-haml
syntax_tree-rbs
yard
)
gem install --no-document "${packages[@]}"
}

View File

@@ -23,33 +23,8 @@ fi
if command-exists rustup; then
setup-completions rustup "$(command-path rustup)" rustup completions zsh
if command-exists cargo; then
setup-completions cargo "$(command-path cargo)" rustup completions zsh cargo
fi
fi
# ==============================================================================
# global rust packages
# ==============================================================================
install_rust_global_packages() {
(
set -e
if ! command-exists rustup; then
read -q "REPLY?Rustup was not found. Install it? [y/N] " &&
echo &&
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
fi
if ! command-exists rustup; then
echo "Rustup was not found. Aborting."
return 1
fi
rustup component add \
rust-analyzer \
rust-src
)
}
if command-exists cargo; then
setup-completions cargo "$(command-path cargo)" rustup completions zsh cargo
fi