-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
geloman
committed
Dec 10, 2024
1 parent
9f2680d
commit 8f01b5a
Showing
1 changed file
with
13 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,52 +1,31 @@ | ||
# SOURCE THESE | ||
# ----------------------------------- | ||
[ -f ~/.dotfiles/.aliasrc ] && . ~/.dotfiles/.aliasrc | ||
[ -f ~/.dotfiles/bash/.bash_prompt ] && . ~/.dotfiles/bash/.bash_prompt | ||
[ -f ~/.fzf.bash ] && . ~/.fzf.bash | ||
[ -f ~/.dotfiles/.aliasrc ] && . ~/.dotfiles/aliasrc | ||
[ -n "$(command -v fzf)" ] && . ~/.dotfiles/fzf/.fzf.bash | ||
|
||
# ADD THESE TO PATH | ||
# ----------------------------------- | ||
[ -d ~/.local/bin ] && PATH=$PATH:$HOME/.local/bin | ||
[ -d ~/.dotfiles/handy-scripts/bin ] && PATH=$PATH:~/.dotfiles/handy-scripts/bin | ||
[ -d ~/.cargo ] && PATH=$PATH:$HOME/.cargo/bin | ||
[ -d ~/.local/share/nvim/mason/bin ] && PATH=$PATH:$HOME/.local/share/nvim/mason/bin | ||
|
||
# CUSTOM FUNCTIONS | ||
# ----------------------------------- | ||
fast_cd() { | ||
selected=$(fast-cd); [ -z "$selected" ] || cd "$selected" || return | ||
} | ||
change_worktree() { | ||
selected=$(git-worktree); [ -n "$selected" ] && cd "$selected" || return | ||
} | ||
[ -d ~/.cargo ] && PATH="$PATH:$HOME/.cargo/bin" | ||
[ -d ~/.local/bin ] && PATH="$PATH:$HOME/.local/bin" | ||
[ -d ~/.dotfiles/handy-scripts/bin ] && PATH="$PATH:~/.dotfiles/handy-scripts/bin" | ||
|
||
# CUSTOM KEYMAPS | ||
# ----------------------------------- | ||
bind -x '"\C-p": tmux-sessionizer' | ||
bind -x '"\C-b": randbg' | ||
bind -x '"\C-f": find-files' | ||
bind '"\C-o": "fast_cd; clear\n"' | ||
bind '"\C-n": "change_worktree; clear\n"' | ||
|
||
## ALL ENVIRONMENT VARIABLE GOES HERE | ||
# ----------------------------------- | ||
SHELL="/usr/bin/bash" | ||
[ -n "$(command -v nvim)" ] && EDITOR="nvim" || EDITOR="vim" | ||
|
||
PINK=#FF52A2 | ||
PURPLE=#DAB8F3 | ||
BG=#2a324a | ||
FG=#93a4c3 | ||
MINT=#00FFAB | ||
WHITE=#EDEDED | ||
|
||
export PATH EDITOR SHELL | ||
[ -f ~/.fzf.bash ] && export FZF_DEFAULT_OPTS="--ansi --color=bg+:$BG,fg+:$FG,gutter:-1,border:$PURPLE,hl:$MINT,hl+:$PINK,query:$PINK,pointer:$PINK,label:$WHITE,info:$MINT,spinner:$PURPLE,header:$PURPLE --border=rounded" | ||
|
||
. "$HOME/.cargo/env" | ||
EDITOR="nvim" | ||
FZF_CTRL_R_OPTS="--border-label ' command history '" | ||
FZF_CTRL_T_OPTS="--border-label ' relative files '" | ||
FZF_ALT_C_OPTS="--border-label ' relative directories '" | ||
FZF_DEFAULT_OPTS_FILE="$HOME/.dotfiles/fzf/.fzfrc" | ||
[ -z "$(command -v nvim)" ] && EDITOR="vim" | ||
export PATH EDITOR | ||
|
||
# opam configuration | ||
[ -n "$(command -v opam)" ] && eval "$(opam env)" | ||
|
||
# starship configuration | ||
# [ -n "$(command -v starship)" ] && eval "$(starship init zsh)" | ||
[ -n "$(command -v starship)" ] && eval "$(starship init bash)" |