-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.bash_aliases
52 lines (47 loc) · 2.43 KB
/
.bash_aliases
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
# manage dotfiles
alias config='/usr/bin/git --git-dir=$HOME/.cfg/ --work-tree=$HOME'
# directories
alias work='cd ~/IWR/'
alias stud='cd ~/Nextcloud/Studium/'
# productivity shortcuts
alias rgrep='grep -R'
alias ll='ls -l'
alias rm='rm -I'
alias e='emacsclient -nc'
alias eb='emacsclient -n'
alias open='xdg-open'
alias bgd="bg && disown"
alias ssh-dontstore="ssh -o \"UserKnownHostsFile /dev/null\""
alias linesofcode='f(){ ( find . -name "$@" -print0 | xargs -0 cat ) | wc -l; unset -f f; }; f'
alias unixtime='date +%s'
alias mountiso='mount -o loop -t iso9660'
alias condaStart='eval "$(/home/conrad/miniconda3/bin/conda shell.zsh hook)" '
alias condaStop='conda deactivate'
alias getLoad='ps -o %cpu,%mem,cmd -C'
alias initRemoteGit='~/scripts/initRemoteGit.sh'
alias ip='ip --color'
alias ipb='ip --color --brief'
alias dmesg="dmesg -T"
alias tempDocker='docker run --rm -it -v ~/dockerTransfer/:/transfer'
alias pandocMarkdownToHTML='f(){ pandoc "$@" -f markdown -t html -s --mathjax; unset -f f; }; f'
alias remoteWindows="rdesktop -g 1280x720 -r sound:off -r disk:share=/home/conrad/dockerTransfer -x l -z -P -u Administrator -p -"
alias containerMe='sudo systemd-nspawn -xD / -u $USER'
alias shrinkPdf='f(){ gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/ebook -dNOPAUSE -dBATCH -dQUIET -sOutputFile=small_"$@" "$@" }; f'
# network
alias wieistmeineip='~/scripts/queryIP.sh'
alias hostsonline='nmap -sP 192.168.178.1/24'
alias availableciphers='nmap -sV --script ssl-enum-ciphers -p 443'
alias simpleHttp='python -m http.server 8000 --bind 127.0.0.1'
# arch
alias checkup='~/scripts/mycheckupdate.sh'
alias pacclean3='sudo paccache -rk3'
alias getmirrors='curl -s "https://www.archlinux.org/mirrorlist/?country=DE&protocol=https&use_mirror_status=on" | sed -e 's/^#Server/Server/' -e '/^#/d' | rankmirrors -n 5 -'
# misc
alias wetterHD='curl wttr.in/Heidelberg,Germany'
alias tellme='fortune -o | cowsay'
alias downloadVideo="youtube-dl -f 'bestvideo+bestaudio' --merge-output-format mkv"
alias downloadAudio="youtube-dl --extract-audio --audio-format mp3"
alias webcamMplayer='mplayer tv:// -tv driver=v4l2:width=640:height=480:device=/dev/video0 -fps 15 -vf screenshot'
alias toggleSleep='xfconf-query -c xfce4-power-manager -p /xfce4-power-manager/presentation-mode -T'
alias toggleDisturb='xfconf-query -c xfce4-notifyd -p /do-not-disturb -T'
alias myHcloud='hcloud server create --image debian-9 --ssh-key conrad@kronos --user-data-from-file ~/hcloud-init'