blob: 6474a3bc6d516343c795b41e66b1b8a0408d3300 (
plain)
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
|
# ~/.bashrc: executed by bash(1) for non-login shells.
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
# don't put duplicate lines or lines starting with space in the history.
HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
HISTSIZE=1000
HISTFILESIZE=2000
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# set a fancy prompt
case "$TERM" in
*-256color) color_prompt=yes;;
esac
# colored GCC warnings and errors
export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# Alias definitions
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# Set vi mode as the default mode
set -o vi
# Opam configuration
test -r /home/filipek/.opam/opam-init/init.sh && . /home/filipek/.opam/opam-init/init.sh > /dev/null 2> /dev/null || true
# Set options for some frequently used programs
export LS_OPTIONS='-lha --color=auto'
export TAR_EXTRACT='-xvzf'
export TAR_ARCHIVE='-cvzf'
export MKDIR_OPTIONS='-p'
export RSYNC_OPTIONS='-rtvzP'
export MANPAGER="vim -M +MANPAGER - "
export SCRIPTS=$HOME/.scripts
export PATH=$SCRIPTS:$HOME/.cargo/bin:$HOME/.local/bin:$PATH
export EDITOR="vim"
export BROWSER="librewolf"
# GPG Config
GPG_TTY=$(tty)
export GPG_TTY
# Prompt colors
export PS1="\[$(tput setaf 2)\]\u\[$(tput setaf 35)\]@\[$(tput setaf 10)\]\h \[$(tput setaf 33)\]\w \[$(tput sgr0)\]$ "
force_color_prompt=yes
# Run these scripts at login
remaps
# After every command, switch to insert mode automatically
bind -m vi-command 'RETURN':vi-insert-mode
# Make it so that Ctrl+L works in vi mode
bind -m vi-command '"\C-l": clear-screen'
bind -m vi-insert '"\C-l": clear-screen'
|