diff --git a/home/sam/config/zsh/local.zsh b/home/sam/config/zsh/local.zsh new file mode 100644 index 0000000..5fe867f --- /dev/null +++ b/home/sam/config/zsh/local.zsh @@ -0,0 +1,95 @@ +export PATH="$HOME/.cargo/bin:$HOME/.atuin/bin:$HOME/.local/bin:$HOME/.fzf/bin:$PATH" + +export OPENAI_API_KEY="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" + +export TAVILY_API_KEY="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" + +#export GEMINI_API_KEY="AIzaSyAoCOjfPH3HigI6aFFAmg9eVhaHMimM7ak" +export DEEPSEEK_API_KEY="sk-26c66e4dd5b34017bd66f7aef748c625" + + + +export EDITOR="nvim" +export VISUAL="nvim" + + +# This must be at the top for Powerlevel10k Instant Prompt to work. +if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then + source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" +fi + +# === Oh My Zsh Configuration === +# Path to your Oh My Zsh installation. +export ZSH="$HOME/.oh-my-zsh" + +# Set the Powerlevel10k theme. +ZSH_THEME="powerlevel10k/powerlevel10k" + +# Which plugins would you like to load? +plugins=(git zsh-autosuggestions zsh-syntax-highlighting) + + +# === Custom PATH Configuration === +# This is the most critical fix. We set the PATH *before* sourcing Oh My Zsh. +# This ensures all custom commands are available to the shell and plugins. +export PATH="$HOME/.local/bin:$HOME/.fzf/bin:$PATH" + + +# === Source Oh My Zsh === +# This line loads the Oh My Zsh framework. All customisations must come after this. +source $ZSH/oh-my-zsh.sh + + +# === Custom Tool Configuration === +# All your custom tools are configured here, after OMZ has loaded. + +# 1. Bat (Better Cat) +# On Debian/Ubuntu, the binary is often 'batcat'. If 'bat' is not found, +# change this alias to 'batcat'. +alias cat='bat --color=always --paging=never' + +# 2. Eza Aliases (Modern replacement for 'ls') +alias ls='eza --icons --git' +alias ll='eza -l --icons --git' +alias la='eza -la --icons --git' +alias tree='eza --tree' + +# 3. Zoxide (Smarter cd) +eval "$(zoxide init zsh)" + +# 4. Atuin (Shell History) +# Your existing Atuin config. +eval "$(atuin init zsh)" +bindkey '^[[A' atuin-up-search # Up arrow +bindkey '^[[B' atuin-down-search # Down arrow + +# 5. FZF (Fuzzy Finder) +# The official script handles keybindings (Ctrl+T) and completions. +[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh + +# 6. Carapace (Completion Engine) +# This will now work because the PATH is set correctly above. +source <(carapace-bin _carapace zsh) + + +# === Load Powerlevel10k Theme === +# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh. +# This must be the very last thing in your .zshrc +[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh + +alias cat='batcat --color=always --paging=never' + +export ANDROID_HOME=$HOME/android-sdk +export PATH=$PATH:$ANDROID_HOME/cmdline-tools/latest/bin:$ANDROID_HOME/platform-tools +# Source ESP-IDF environment +# IMPORTANT: Adjust path if your ESP-IDF installation moves +if [ -d "/home/sam/esp/esp-idf" ]; then + . "/home/sam/esp/esp-idf/export.sh" +fi + +# opencode +export PATH=/home/sam/.opencode/bin:$PATH + +export NVM_DIR="$HOME/.nvm" +[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm +[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion