Add folds (markers)

master
Hektor Misplon 2022-10-25 20:54:01 +02:00
parent b355d5a802
commit 9856b53ef9
1 changed files with 35 additions and 12 deletions

47
.bashrc
View File

@ -1,13 +1,12 @@
# If not running interactively, don't do anything # If not running interactively, don't do anything
[[ $- != *i* ]] && return [[ $- != *i* ]] && return
# Aliases {{{
# Load aliases dynamically # Load aliases dynamically
[ -f "$HOME/.bash_aliases" ] && source "$HOME/.bash_aliases" [ -f "$HOME/.bash_aliases" ] && source "$HOME/.bash_aliases"
# }}}
# Add ~/.bin to PATH # Prompt {{{
export PATH=~/.bin:$PATH
# Prompt
get_branch_name() { get_branch_name() {
git symbolic-ref --quiet --short HEAD 2>/dev/null \ git symbolic-ref --quiet --short HEAD 2>/dev/null \
|| git rev-parse --short HEAD 2>/dev/null \ || git rev-parse --short HEAD 2>/dev/null \
@ -19,17 +18,32 @@ get_git_info() {
} }
export PS1="\u \w ❭\[$(tput sgr0)\] " export PS1="\u \w ❭\[$(tput sgr0)\] "
# History
# Ellipsis when deep in directory
export PROMPT_DIRTRIM=2
# }}}
# Path {{{
# Add ~/.bin to PATH
export PATH=~/.bin:$PATH
# }}}
# History {{{
export HISTCONTROL=ignoreboth:erasedups export HISTCONTROL=ignoreboth:erasedups
export HISTSIZE=500000 export HISTSIZE=500000
# Omit `clear, ls...`; commands prepended with space # Omit `clear, ls...`; commands prepended with space
export HISTIGNORE="clear:l: *" export HISTIGNORE="clear:l: *"
# }}}
# Man pages # Man pages {{{
export MANWIDTH=120 export MANWIDTH=120
# }}}
# Editor {{{
# Set vim as default editor
export EDITOR=nvim
# }}}
# Vim
export EDITOR=vim
# Fuzzy finder setup # Fuzzy finder setup
export FZF_COMPLETION_TRIGGER='**' export FZF_COMPLETION_TRIGGER='**'
@ -51,11 +65,20 @@ export PATH=~/.nvm/versions/node/v14.16.0/bin:$PATH
export NVM_DIR="$HOME/.nvm" export NVM_DIR="$HOME/.nvm"
[[ -s "$NVM_DIR/nvm.sh" ]] && source "$NVM_DIR/nvm.sh" --no-use [[ -s "$NVM_DIR/nvm.sh" ]] && source "$NVM_DIR/nvm.sh" --no-use
# X11 # X11 {{{
export XDG_SESSION_TYPE=X11 export XDG_SESSION_TYPE=X11
# }}}
# Jupyter # Nix package manager {{{
# }}}
# FZF {{{
# }}}
# Node {{{
# }}}
# Jupyter {{{
export JUPYTERLAB_DIR=$HOME/.local/share/jupyter/lab export JUPYTERLAB_DIR=$HOME/.local/share/jupyter/lab
# }}}
# Ellipsis when deep in directory
export PROMPT_DIRTRIM=2