Merge remote-tracking branch 'origin/master'

This commit is contained in:
2026-02-24 16:08:51 +00:00
15 changed files with 47 additions and 34 deletions

View File

@@ -56,6 +56,8 @@ let g:netrw_browse_split = 4
set background=dark set background=dark
if has('termguicolors') && ($COLORTERM ==# 'truecolor' || $COLORTERM ==# '24bit') if has('termguicolors') && ($COLORTERM ==# 'truecolor' || $COLORTERM ==# '24bit')
let &t_8f = "\<Esc>[38;2;%lu;%lu;%lum"
let &t_8b = "\<Esc>[48;2;%lu;%lu;%lum"
set termguicolors set termguicolors
endif endif

View File

@@ -1,6 +1,9 @@
# Profiling: ZSH_BENCH=1 zsh # Profiling: ZSH_BENCH=1 zsh
[[ -n "$ZSH_BENCH" ]] && zmodload zsh/zprof [[ -n "$ZSH_BENCH" ]] && zmodload zsh/zprof
# Upgrade xterm-color to xterm-256color (gh cs ssh sets the weaker value)
[[ "$TERM" == "xterm-color" ]] && export TERM=xterm-256color
# Assume truecolor support if terminal advertises 256color (covers SSH, tmux) # Assume truecolor support if terminal advertises 256color (covers SSH, tmux)
[[ -z "$COLORTERM" && "$TERM" == *256color* ]] && export COLORTERM=truecolor [[ -z "$COLORTERM" && "$TERM" == *256color* ]] && export COLORTERM=truecolor

View File

@@ -8,10 +8,10 @@
log_info "Environment: DOTS_OS=$DOTS_OS, DOTS_PKG=$DOTS_PKG, DOTS_ENV=$DOTS_ENV" log_info "Environment: DOTS_OS=$DOTS_OS, DOTS_PKG=$DOTS_PKG, DOTS_ENV=$DOTS_ENV"
if [[ "$DOTS_OS" == "macos" ]]; then if [[ "$DOTS_OS" == "macos" ]]; then
sw_vers sw_vers 2>&1 | log_quote
elif [[ "$DOTS_OS" == "linux" ]]; then elif [[ "$DOTS_OS" == "linux" ]]; then
if [[ -r /etc/os-release ]]; then if [[ -r /etc/os-release ]]; then
cat /etc/os-release log_quote < /etc/os-release
fi fi
if [[ -z "$DOTS_PKG" ]]; then if [[ -z "$DOTS_PKG" ]]; then

View File

@@ -15,5 +15,5 @@ if ! command -v brew &> /dev/null; then
else else
echo "Homebrew is already installed." echo "Homebrew is already installed."
fi fi
brew --version brew --version | log_quote
log_pass "Homebrew installed" log_pass "Homebrew installed"

View File

@@ -17,10 +17,17 @@ apt_packages=(
wget wget
) )
# Skip if all packages already installed
if dpkg -s "${apt_packages[@]}" &>/dev/null; then
apt --version | log_quote
return 0
fi
sudo apt-get update -qq sudo apt-get update -qq
sudo apt-get install -qq "${apt_packages[@]}" sudo apt-get install -qq "${apt_packages[@]}"
unset apt_packages unset apt_packages
apt --version apt --version | log_quote
log_pass "apt packages installed" log_pass "apt packages installed"

View File

@@ -30,6 +30,6 @@ if ! command -v yay &>/dev/null; then
rm -rf /tmp/yay rm -rf /tmp/yay
fi fi
pacman --version pacman --version | log_quote
yay --version yay --version | log_quote
log_pass "pacman packages installed" log_pass "pacman packages installed"

View File

@@ -6,7 +6,7 @@
# #
# Skip in Codespaces (pre-installed in universal image) # Skip in Codespaces (pre-installed in universal image)
[[ "$DOTS_ENV" == "codespaces" ]] && { log_skip "Codespaces"; git --version; return 0; } [[ "$DOTS_ENV" == "codespaces" ]] && { git --version | log_quote; return 0; }
if ! command -v git &> /dev/null; then if ! command -v git &> /dev/null; then
case "$DOTS_PKG" in case "$DOTS_PKG" in
@@ -26,5 +26,5 @@ if ! command -v git &> /dev/null; then
esac esac
fi fi
git --version git --version | log_quote
log_pass "git configured" log_pass "git configured"

View File

@@ -24,7 +24,7 @@ if ! command -v zsh &> /dev/null; then
esac esac
fi fi
zsh --version zsh --version | log_quote
# plugin directory (XDG compliant) # plugin directory (XDG compliant)
PLUGIN_DIR="${XDG_DATA_HOME:-$HOME/.local/share}/zsh/plugins" PLUGIN_DIR="${XDG_DATA_HOME:-$HOME/.local/share}/zsh/plugins"
@@ -50,4 +50,3 @@ if [[ "$SHELL" != *zsh ]]; then
sudo usermod -s "$(command -v zsh)" "$(whoami)" sudo usermod -s "$(command -v zsh)" "$(whoami)"
fi fi
log_pass "zsh configured"

View File

@@ -23,7 +23,7 @@ if ! command -v stow &> /dev/null; then
esac esac
fi fi
stow --version stow --version | log_quote
root_dir=${DOTFILES:-$(dirname "$(dirname "$(dirname "$(realpath "$0")")")")} root_dir=${DOTFILES:-$(dirname "$(dirname "$(dirname "$(realpath "$0")")")")}
@@ -43,4 +43,3 @@ stow --dir="$root_dir" --target="$HOME" home
# Bust PATH cache to force regeneration with new profile # Bust PATH cache to force regeneration with new profile
rm -f "${XDG_CACHE_HOME:-$HOME/.cache}/dots/path" rm -f "${XDG_CACHE_HOME:-$HOME/.cache}/dots/path"
log_pass "stow linked"

View File

@@ -23,5 +23,5 @@ if ! command -v tmux &> /dev/null; then
esac esac
fi fi
tmux -V tmux -V | log_quote
log_pass "tmux installed"

View File

@@ -15,6 +15,7 @@ if ! command -v mise &>/dev/null; then
;; ;;
apt) apt)
# https://mise.jdx.dev/getting-started.html#apt-debian-ubuntu # https://mise.jdx.dev/getting-started.html#apt-debian-ubuntu
sudo install -dm 755 /etc/apt/keyrings
wget -qO - https://mise.jdx.dev/gpg-key.pub | gpg --dearmor | \ wget -qO - https://mise.jdx.dev/gpg-key.pub | gpg --dearmor | \
sudo tee /etc/apt/keyrings/mise-archive-keyring.gpg 1> /dev/null sudo tee /etc/apt/keyrings/mise-archive-keyring.gpg 1> /dev/null
echo "deb [signed-by=/etc/apt/keyrings/mise-archive-keyring.gpg arch=amd64] https://mise.jdx.dev/deb stable main" | \ echo "deb [signed-by=/etc/apt/keyrings/mise-archive-keyring.gpg arch=amd64] https://mise.jdx.dev/deb stable main" | \
@@ -35,7 +36,7 @@ if ! command -v mise &>/dev/null; then
esac esac
fi fi
mise --version echo "mise $(mise --version)" | log_quote
# Skip runtimes in Codespaces (use pre-installed versions) # Skip runtimes in Codespaces (use pre-installed versions)
if [[ "$DOTS_ENV" != "codespaces" ]]; then if [[ "$DOTS_ENV" != "codespaces" ]]; then
@@ -73,7 +74,6 @@ if [[ "$DOTS_ENV" != "codespaces" ]]; then
fi fi
log_info "Installing apps..." log_info "Installing apps..."
mise install "${MISE_APPS[@]}"
for tool in "${MISE_APPS[@]}"; do for tool in "${MISE_APPS[@]}"; do
mise use -g "$tool" mise use -g "$tool"
done done
@@ -89,6 +89,7 @@ fi
# Verify installations # Verify installations
log_info "Verifying installations..." log_info "Verifying installations..."
{
if [[ "$DOTS_ENV" != "codespaces" ]]; then if [[ "$DOTS_ENV" != "codespaces" ]]; then
mise exec -- python --version mise exec -- python --version
mise exec -- poetry --version mise exec -- poetry --version
@@ -99,8 +100,9 @@ if [[ "$DOTS_ENV" != "codespaces" ]]; then
echo "firebase: $(mise exec -- firebase --version)" echo "firebase: $(mise exec -- firebase --version)"
echo "fastfetch: $(mise exec -- fastfetch --version 2>&1 | head -1)" echo "fastfetch: $(mise exec -- fastfetch --version 2>&1 | head -1)"
fi fi
fzf --version echo "fzf $(fzf --version)"
zoxide --version zoxide --version
rg --version | head -1 rg --version | head -1
delta --version | head -1 delta --version | head -1
} | log_quote
log_pass "mise tools installed" log_pass "mise tools installed"

View File

@@ -56,5 +56,5 @@ if ! groups "$USER" | grep -q "\b$docker_group\b"; then
sudo usermod -aG docker "$USER" sudo usermod -aG docker "$USER"
fi fi
docker --version docker --version | log_quote
log_pass "Docker configured" log_pass "Docker configured"

View File

@@ -26,5 +26,5 @@ if ! command -v az &>/dev/null; then
esac esac
fi fi
az --version az --version | log_quote
log_pass "Azure CLI installed" log_pass "Azure CLI installed"

View File

@@ -31,5 +31,5 @@ if ! command -v redis-cli &>/dev/null; then
esac esac
fi fi
redis-cli --version redis-cli --version | log_quote
log_pass "Redis installed" log_pass "Redis installed"

View File

@@ -32,9 +32,10 @@ log_skip() { echo -e "${GREY}[SKIP]${NC} $*"; }
log_warn() { echo -e "${YELLOW}[WARN]${NC} $*"; } log_warn() { echo -e "${YELLOW}[WARN]${NC} $*"; }
log_error() { echo -e "${RED}[FAIL]${NC} $*"; } log_error() { echo -e "${RED}[FAIL]${NC} $*"; }
log_debug() { echo -e "${CYAN}$*${NC}"; } log_debug() { echo -e "${CYAN}$*${NC}"; }
log_quote() { sed "s/^/ ${GREY}│ /" | sed "s/$/${NC}/"; }
# Export log functions # Export log functions
export -f log_info log_pass log_skip log_warn log_error log_debug export -f log_info log_pass log_skip log_warn log_error log_debug log_quote
printf "\n\t${CYAN} <<< ${CYAN_BOLD}dots${CYAN} >>> ${NC}\n" printf "\n\t${CYAN} <<< ${CYAN_BOLD}dots${CYAN} >>> ${NC}\n"
printf "\t${GREY}==============${NC}\n\n" printf "\t${GREY}==============${NC}\n\n"