Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Brewfile
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,8 @@ brew "ctags"
brew "diffutils"
# Activates NFS on docker-machine
brew "docker-machine-nfs"
# Modern replacement for ls with git integration and icons
brew "eza"
# Image processing and image analysis library
brew "leptonica"
# Subtitle renderer for the ASS/SSA subtitle format
Expand Down Expand Up @@ -259,6 +261,8 @@ brew "wxwidgets"
brew "yarn"
# Process YAML, JSON, XML, CSV and properties documents from the CLI
brew "yq"
# Smarter cd command (jump to frecent directories)
brew "zoxide"
# Kubernetes CLI To Manage Your Clusters In Style!
brew "derailed/k9s/k9s"
# Vault
Expand Down
22 changes: 11 additions & 11 deletions dot_bash_profile.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,15 @@ path_append "$HOME/.opencode/bin"
export CHEZMOI_GH_TOKEN_OP_REF='{{ if hasKey . "gh" }}{{ .gh.tokenOpRef }}{{ else }}{{ env "CHEZMOI_GH_TOKEN_OP_REF" }}{{ end }}'
{{- end }}

if [ -d "$HOME/.config/chezmoi/profile.d" ]; then
for _chez_profile_d in "$HOME"/.config/chezmoi/profile.d/*.sh; do
[ -r "$_chez_profile_d" ] || continue
# shellcheck source=/dev/null
. "$_chez_profile_d"
done
unset _chez_profile_d
fi

{{- if ne .chezmoi.os "windows" }}
if [ -z "$INTELLIJ_ENVIRONMENT_READER" ] && command -v mise >/dev/null 2>&1; then
eval "$(mise activate bash)"
Expand All @@ -114,8 +123,8 @@ if [ -z "$INTELLIJ_ENVIRONMENT_READER" ] && command -v mise >/dev/null 2>&1; the
export __MISE_EXE
fi
fi
if [ -z "$INTELLIJ_ENVIRONMENT_READER" ] && command -v zoxide >/dev/null 2>&1; then
eval "$(zoxide init bash)"
if type chez_init_zoxide_cd >/dev/null 2>&1; then
chez_init_zoxide_cd
fi
{{- end }}

Expand Down Expand Up @@ -166,15 +175,6 @@ aprompt () {
oprompt "$@"
}

if [ -d "$HOME/.config/chezmoi/profile.d" ]; then
for _chez_profile_d in "$HOME"/.config/chezmoi/profile.d/*.sh; do
[ -r "$_chez_profile_d" ] || continue
# shellcheck source=/dev/null
. "$_chez_profile_d"
done
unset _chez_profile_d
fi

ghpersonalauth () {
local config_dir
config_dir="${CHEZMOI_GH_CONFIG_DIR:-$HOME/.config/gh-personal}"
Expand Down
3 changes: 3 additions & 0 deletions dot_config/bat/config
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Match Neovim tokyonight-night (see dot_config/bat/themes/tokyonight_night.tmTheme).
--theme="tokyonight_night"
--style="plain"

# Chezmoi templates use .tmpl; map to Bash (see ranger executable_scope.sh).
--map-syntax="*.tmpl:Bash"
13 changes: 13 additions & 0 deletions dot_config/chezmoi/profile.d/00-agent-shell.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Agent subprocess detection for profile.d consumers (e.g. zoxide-init).
# Load first (00- prefix) so later snippets can branch before smart-cd init.

_is_agent_shell() {
# Cursor IDE / CLI agent (https://cursor.com/docs/agent/tools/terminal)
[ -n "${CURSOR_AGENT:-}" ] && return 0
# Claude Code bash tool / hooks (https://code.claude.com/docs/en/env-vars)
[ "${CLAUDECODE:-}" = "1" ] && return 0
# Explicit opt-in for other agent shells (e.g. OpenCode bash tool via
# opencode.json "env": { "CUSTOM_AGENT_SHELL": "1" })
[ -n "${CUSTOM_AGENT_SHELL:-}" ] && return 0
return 1
}
10 changes: 10 additions & 0 deletions dot_config/chezmoi/profile.d/eza-aliases.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Directory listing aliases backed by eza (https://github.com/eza-community/eza).
if command -v eza >/dev/null 2>&1; then
alias ls='eza --color=auto --group-directories-first --icons=auto'
alias l='eza --color=auto --group-directories-first --icons=auto'
alias ll='eza -l --color=auto --group-directories-first --icons=auto --git'
alias la='eza -a --color=auto --group-directories-first --icons=auto'
alias lla='eza -la --color=auto --group-directories-first --icons=auto --git'
alias lt='eza --tree --color=auto --group-directories-first --icons=auto'
alias lS='eza -l --sort=size --color=auto --group-directories-first --icons=auto'
fi
28 changes: 28 additions & 0 deletions dot_config/chezmoi/profile.d/zoxide-init.sh.tmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{{- if ne .chezmoi.os "windows" }}
# zoxide: replace cd with smart jumps in human shells. Loaded from profile.d but
# must run after mise activate (see dot_bash_profile / dot_zshrc) so mise does not
# overwrite zoxide's cd with __zsh_like_cd.

chez_init_zoxide_cd() {
if [ -n "${INTELLIJ_ENVIRONMENT_READER:-}" ] || ! command -v zoxide >/dev/null 2>&1; then
return 0
fi
if type _is_agent_shell >/dev/null 2>&1 && _is_agent_shell; then
return 0
fi

if [ -n "${ZSH_VERSION:-}" ]; then
eval "$(zoxide init zsh --cmd cd)"
else
eval "$(zoxide init bash --cmd cd)"
# Bash: zoxide uses plain `builtin cd` and does not run chpwd_functions, so
# re-wrap __zoxide_cd to keep mise hook-env on directory changes.
if declare -F _mise_hook_chpwd >/dev/null 2>&1 && declare -F __zoxide_cd >/dev/null 2>&1; then
eval "$(declare -f __zoxide_cd | sed '1s/__zoxide_cd/__zoxide_cd_orig/')"
__zoxide_cd() {
__zoxide_cd_orig "$@" && _mise_hook_chpwd
}
fi
fi
}
{{- end }}
6 changes: 6 additions & 0 deletions dot_config/jj/config.toml.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,12 @@ email = {{ .git.personal.email | quote }}
[--scope.signing]
key = {{ .git.personal.signingkey | quote }}

# Delta does not recognize .tmpl; default to Bash in chezmoi/dotfiles repos.
[[--scope]]
--when.repositories = [{{ $dotfilesRepoDir | quote }}, {{ $chezmoiSourceDir | quote }}]
[--scope.ui]
pager = ["delta", "--default-language", "bash"]

[[--scope]]
--when.repositories = ["~/dev/repos/github.com/{{ $personalGithubUser }}"]
[--scope.user]
Expand Down
4 changes: 4 additions & 0 deletions dot_gitconfig-chezmoi.tmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Chezmoi source uses .tmpl extensions that delta/syntect do not recognize.
# Treat unknown extensions as Bash (matches ranger preview and most tmpl content).
[delta]
default-language = bash
8 changes: 8 additions & 0 deletions dot_gitconfig.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -134,3 +134,11 @@
path = ~/.gitconfig-personal
[includeIf "gitdir/i:{{ $chezmoiSourceGitDir }}"]
path = ~/.gitconfig-personal
[includeIf "gitdir:{{ $chezmoiSourceGitDir }}"]
path = ~/.gitconfig-chezmoi
[includeIf "gitdir/i:{{ $chezmoiSourceGitDir }}"]
path = ~/.gitconfig-chezmoi
[includeIf "gitdir:{{ $dotfilesGitDir }}"]
path = ~/.gitconfig-chezmoi
[includeIf "gitdir/i:{{ $dotfilesGitDir }}"]
path = ~/.gitconfig-chezmoi
11 changes: 5 additions & 6 deletions dot_tool-versions
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
dart 2.19.6
java corretto-21.0.2.13.1
python 3.13.0
dart 2.19.6
java corretto-21.0.2.13.1
golang latest
nodejs 18.20.8
maven 3.9.11
pnpm latest
vale latest
maven 3.9.11
pnpm latest
vale latest
21 changes: 12 additions & 9 deletions dot_zshrc.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,15 @@ export AI_TERM_CMD="opencode"
export CHEZMOI_GH_TOKEN_OP_REF='{{ if hasKey . "gh" }}{{ .gh.tokenOpRef }}{{ else }}{{ env "CHEZMOI_GH_TOKEN_OP_REF" }}{{ end }}'
{{- end }}

if [[ -d "$HOME/.config/chezmoi/profile.d" ]]; then
for _chez_profile_d in "$HOME"/.config/chezmoi/profile.d/*.sh(N); do
[[ -r "$_chez_profile_d" ]] || continue
# shellcheck source=/dev/null
. "$_chez_profile_d"
done
unset _chez_profile_d
fi

{{- if ne .chezmoi.os "windows" }}
if command -v mise >/dev/null 2>&1; then
eval "$(mise activate zsh)"
Expand All @@ -21,6 +30,9 @@ if command -v mise >/dev/null 2>&1; then
export __MISE_EXE
fi
fi
if typeset -f chez_init_zoxide_cd >/dev/null 2>&1; then
chez_init_zoxide_cd
fi
if [ -z "${INTELLIJ_ENVIRONMENT_READER:-}" ] && [ -f "$HOME/.config/oh-my-posh/shell-init.sh" ]; then
# shellcheck source=/dev/null
. "$HOME/.config/oh-my-posh/shell-init.sh" zsh
Expand Down Expand Up @@ -54,15 +66,6 @@ aprompt () {
oprompt "$@"
}

if [[ -d "$HOME/.config/chezmoi/profile.d" ]]; then
for _chez_profile_d in "$HOME"/.config/chezmoi/profile.d/*.sh(N); do
[[ -r "$_chez_profile_d" ]] || continue
# shellcheck source=/dev/null
. "$_chez_profile_d"
done
unset _chez_profile_d
fi

ghpersonalauth () {
local config_dir
config_dir="${CHEZMOI_GH_CONFIG_DIR:-$HOME/.config/gh-personal}"
Expand Down
Loading