blob: cce2dc81dda64f7629559bebe4652fe2a40c30ff (
about) (
plain) (
blame)
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
|
# various bash tweaks
shopt -s histappend
shopt -s cmdhist
HISTSIZE=
HISTFILESIZE=
HISTCONTROL=ignoreboth
HISTIGNORE='ls:l:s:bg:fg:history'
HISTTIMEFORMAT='%F %T '
stty stop ""
# aliases
alias ls='ls --color=auto'
alias mpv="mpv --ytdl-format mp4"
alias mv="mv -iv"
alias cp="cp -iv"
alias scl=systemctl
alias jcl=journalctl
alias m="mbsync csclub; mbsync uwaterloo; mbsync amin"
alias best="youtube-dl -f best"
aur() {
cd ~/usr/builds
git clone https://aur.archlinux.org/${1}.git
cd ${1}
}
# i-beam cursor
# echo -e "\033[5 q" # blinking
echo -e "\033[6 q" # non-blinking
# If not running interactively, don't do anything else
[[ $- != *i* ]] && return
a_prompt() {
cwd=$(pwd | sed -e "s!$HOME!~!" | sed -re "s!([^/])[^/]+/!\1/!g")
printf $cwd
}
PS1="\u@\h \$(a_prompt)> "
|