refactor: Remove redundant curl availability checks
Some checks failed
Lint / lint (push) Failing after 56s
Lint / lint (pull_request) Failing after 1m5s

This commit is contained in:
2026-06-26 21:49:24 +05:30
parent 29de051b7d
commit 4c1c7de0b7
7 changed files with 4 additions and 36 deletions

View File

@@ -28,7 +28,7 @@ check_config_dir() {
install_packages() {
log_info "Detecting distribution and installing dependencies..."
pkg_install \
git tar curl unzip ripgrep fzf nodejs npm xclip wl-clipboard \
git tar unzip ripgrep fzf nodejs npm xclip wl-clipboard \
"arch:fd|debian:fd-find|fedora:fd-find" \
"arch:cmake|debian:cmake|fedora:cmake" \
"arch:make|debian:build-essential|fedora:make" \

View File

@@ -15,14 +15,6 @@ cleanup() {
}
trap cleanup EXIT
# Ensure we have curl
install_downloader() {
if ! has_command curl; then
log_info "curl not found. Installing curl..."
pkg_install curl
fi
}
detect_target_triple() {
local ostype
ostype="$(uname -s)"
@@ -60,7 +52,7 @@ install_rust() {
log_info "Rust (rustup) is already installed."
fi
install_downloader
local target
target=$(detect_target_triple)

View File

@@ -20,12 +20,6 @@ install_starship() {
log_info "Starship is already installed."
fi
# Ensure curl is installed
if ! has_command curl; then
log_info "curl not found. Installing curl..."
pkg_install curl
fi
# Detect architecture
local raw_arch
raw_arch=$(detect_arch)

View File

@@ -23,12 +23,6 @@ install_uv() {
fi
fi
# Ensure curl is installed
if ! has_command curl; then
log_info "curl not found. Installing curl..."
pkg_install curl
fi
# Detect architecture
local raw_arch
raw_arch=$(detect_arch)

View File

@@ -9,12 +9,6 @@
set -euo pipefail
install_curl() {
if ! has_command curl; then
log_info "curl not found. Installing curl..."
pkg_install curl
fi
}
install_fzf() {
if has_command fzf; then
@@ -31,7 +25,7 @@ install_zoxide() {
log_info "Zoxide is already installed."
fi
install_curl
log_info "Downloading and running the official zoxide installer..."
curl -sSfL https://raw.githubusercontent.com/ajeetdsouza/zoxide/main/install.sh | sh