4 local -r word
=$
(fzf
< /usr
/share
/dict
/words
)
8 # Top Disk-Using directories
9 # TODO: Consider using numfmt instead of awk
18 sub("^" $1 "\t+", "", path)
19 gb = size / 1024 / 1024
20 printf("%f\t%s\n", gb, path)
25 # Top Disk-Using Files
27 find "$1" -type f
-printf '%s\t%p\0' \
28 |
sort -z -n -k 1 -r \
34 sub("^" $1 "\t+", "", path)
35 gb = size / 1024 / 1024 / 1024
36 printf("%f\t%s\n", gb, path)
40 # Most-recently modified file system objects
43 # - intentionally not quoting the parameters, so that some can be ignored
44 # if not passed, rather than be passed to find as an empty string;
45 # - %T+ is a GNU extension;
46 # - gawk is able to split records on \0, while awk cannot.
47 find $@
-printf '%T@ %T+ %p\0' \
48 |
tee >(gawk
-v RS
='\0' 'END { printf("[INFO] Total found: %d\n", NR); }') \
49 |
sort -z -k 1 -n -r \
50 |
head -n "$(stty size | awk 'NR == 1 {print $1 - 5}')" -z \
53 sub("^" $1 " +", "") # Remove epoch time
54 sub("+", " ") # Blank-out the default separator
55 sub("\\.[0-9]+", "") # Remove fractional seconds
69 pactl info |
awk '/^Default Sink:/ {print $3}'
73 curl
"https://xq-api.voidlinux.org/v1/query/x86_64?q=$1" | jq
'.data'
78 LESS_TERMCAP_md
=$
'\e[01;31m' \
79 LESS_TERMCAP_me
=$
'\e[0m' \
80 LESS_TERMCAP_se
=$
'\e[0m' \
81 LESS_TERMCAP_so
=$
'\e[01;44;33m' \
82 LESS_TERMCAP_ue
=$
'\e[0m' \
83 LESS_TERMCAP_us
=$
'\e[01;32m' \
88 cd "$(~/bin/experiment $@)" ||
exit 1
92 ledit
-l "$(stty size | awk '{print $2}')" ocaml $@
96 cat "$(find ~/Archives/Documents/HOWTOs -mindepth 1 -maxdepth 1 | sort | fzf)"
106 _yt_id
=$
(youtube-dl
--get-id "$_yt_uri")
107 _yt_title
=$
(youtube-dl
--get-title "$_yt_uri")
108 _yt_dir
="${DIR_YOUTUBE}/individual-videos/${_yt_title}--${_yt_id}"
111 cd "$_yt_dir" ||
exit 1
112 echo "$_yt_uri" > 'uri'
113 youtube-dl
-c --write-description --write-info-json "$_yt_uri"
117 curl
"https://api.github.com/$1/$2/repos?page=1&per_page=10000"
123 gh_dir
="${DIR_GITHUB}/${gh_user_name}"
125 cd "$gh_dir" ||
exit 1
126 gh_fetch_repos
"$gh_user_type" "$gh_user_name" \
127 | jq
--raw-output '.[] | select(.fork | not) | .git_url' \
133 gh_clone
'users' "$1"
141 gh_username
=$
(echo "$1" |
awk -F / '"$1 == "https" && $3 == github.com" {print $4}')
142 gh_dir
="${DIR_GITHUB}/${gh_username}"
144 cd "$gh_dir" ||
exit 1
148 work_log_template
() {
168 mkdir
-p "$DIR_WORK_LOG"
169 file_work_log_today
="${DIR_WORK_LOG}/$(date +%F).md"
170 if [ ! -f "$file_work_log_today" ]
172 work_log_template
> "$file_work_log_today"
174 vim
-c 'set spell' "$file_work_log_today"
179 mkdir
-p "$DIR_NOTES"
180 vim
-c 'set spell' "$DIR_NOTES/$(date +'%Y_%m_%d--%H_%M_%S%z')--$1.md"
184 curl
"http://wttr.in/$WEATHER_LOCATION"
188 bluetoothctl
-- paired-devices \
190 |
xargs bluetoothctl
-- info
194 bluetoothctl
-- devices \
196 |
xargs bluetoothctl
-- info
201 $@
2> >(tee "$stderr")
205 0) urgency
='normal';;
206 *) urgency
='critical'
208 notify-send
-u "$urgency" "Job done: $code" "$(cat $stderr)"
This page took 0.114684 seconds and 5 git commands to generate.