blob: ebb27de473add49f95c0a8b9ae4c4c26cd2d22e3 (
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
|
# Software list (Void Linux):
# void-repo-nonfree void-repo-multilib void-repo-multilib-nonfree
# file-roller xfce4-screenshooter xfce4-plugins xsetroot thunar-archive-plugin
# clang clang-tools-extra vim stow git curl tmux hstr tree make cmake
# entr ack lazygit newsboat htop mc
# Only run if the script is being sourced (bashrc).
if [[ "${BASH_SOURCE[0]}" != "${0}" ]]; then
# Magical environment variables.
export COLORTERM=truecolor
export TERM=xterm-256color
export VISUAL=vim
export EDITOR=vim
git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/'
}
# Better prompt.
export PS1='\n# \u@\h \T \w $(git_branch)\n# '
# General aliases.
alias l='ls -lh'
alias ll='ls -lha'
alias t='tree -L 2'
alias ..='cd ..'
alias grep='grep -irn --color=always'
alias less='less -R'
alias tmux='tmux -u'
alias server='python3 -m http.server 6969'
alias newsboat='newsboat -r -u ~/.feeds.txt'
alias ack='ack -S'
alias gg='lazygit'
# Custom folder jump commands.
alias j='cd ~/Junk'
alias p='cd ~/Projects'
alias d='cd ~/Downloads'
# History and search. Stolen from J.
HISTCONTROL=ignoreboth
shopt -s histappend
export HISTSIZE=
export HISTFILESIZE=
export HISTFILE=~/.bash_history_infinite
PROMPT_COMMAND="history -a; history -n; ${PROMPT_COMMAND}"
bind '"\e[A": history-search-backward'
bind '"\e[B": history-search-forward'
export HSTR_CONFIG=hicolor
if [[ $- =~ .i. ]]; then bind '"\C-h": "\C-a hstr -- \C-j"'; fi
fi
wow() {
cd ~/Games/turtlewow && ./wow.sh
}
|