Add SomaFM mpc scripts
[khome.git] / lib / login_functions.sh
CommitLineData
c7de24d9
SK
1# Top Disk-Using directories
2tdu() {
3 du "$1" \
4 | sort -n -k 1 -r --parallel="$(nproc)" \
5 | head -50 \
6 | awk '
7 {
8 size = $1
9 path = $0
10 sub("^" $1 "\t+", "", path)
11 gb = size / 1024 / 1024
12 printf("%f\t%s\n", gb, path)
13 }' \
14 | cut -c 1-115
15}
16
17pa_def_sink() {
18 pactl info | awk '/^Default Sink:/ {print $3}'
19}
20
21void_pkgs() {
22 curl "https://xq-api.voidlinux.org/v1/query/x86_64?q=$1" | jq '.data'
23}
24
25# Colorful man
26man() {
27 LESS_TERMCAP_md=$'\e[01;31m' \
28 LESS_TERMCAP_me=$'\e[0m' \
29 LESS_TERMCAP_se=$'\e[0m' \
30 LESS_TERMCAP_so=$'\e[01;44;33m' \
31 LESS_TERMCAP_ue=$'\e[0m' \
32 LESS_TERMCAP_us=$'\e[01;32m' \
33 command man "$@"
34}
64ec9f23
SK
35
36experiment() {
37 cd "$($HOME/bin/experiment $@)"
38}
801dd7bd
SK
39
40hump() {
41 ledit -l $(stty size | awk '{print $2}') ocaml $@
42}
This page took 0.033193 seconds and 4 git commands to generate.