-
Notifications
You must be signed in to change notification settings - Fork 0
/
dot_bashrc
45 lines (37 loc) · 1.46 KB
/
dot_bashrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# =============================================================================
# .bashrc
# Author: Joakim Engeset <joakim.engeset@gmail.com>
# =============================================================================
# scripts
[[ -f /etc/bashrc ]] && . /etc/bashrc
[[ -f /etc/bash_completion ]] && . /etc/bash_completion
. ~/.tokens
# aliases
aliasfile=$XDG_CONFIG_HOME/shell/aliasrc
. "$aliasfile"
alias ac="e $aliasfile"
# options
shopt -s histappend # Append to the history file
shopt -s checkwinsize # Check the window size after each command
# env vars
export EDITOR=nvim
export HISTSIZE=
export HISTCONTROL=ignoreboth:erasedups
export HISTFILESIZE=
export HISTTIMEFORMAT="%Y/%m/%d %H:%M:%S: "
export COPYFILE_DISABLE=true
export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-8
export XDG_CONFIG_HOME="$HOME/.config"
export PATH=~/go/bin:~/bin:/usr/local/sbin:~/.emacs.d/bin:~/.local/bin/:$PATH
# fzf
export FZF_DEFAULT_COMMAND='fd --type f --hidden'
export FZF_CTRL_T_OPTS="--preview '(highlight -O ansi -l {} 2> /dev/null || cat {} || tree -C {}) 2> /dev/null | head -200'"
export FZF_CTRL_R_OPTS="--preview 'echo {}' --preview-window down:3:hidden --bind '?:toggle-preview'"
command -v blsd >/dev/null && export FZF_ALT_C_COMMAND='blsd'
command -v tree >/dev/null && export FZF_ALT_C_OPTS="--preview 'tree -C {} | head -200'"
# prompt
eval "$(starship init bash)"
. "$HOME/.atuin/bin/env"
[[ -f ~/.bash-preexec.sh ]] && source ~/.bash-preexec.sh
eval "$(atuin init bash)"