| xsel -i -b -t 30000
}
+dl() {
+ local -r timestamp="$(date --iso-8601=ns)"
+ local -r dir="$HOME"/dl/adhoc/"$timestamp"
+ local -r url_file_path="${dir}/url"
+
+ mkdir -p "$dir"
+ touch "$url_file_path"
+ cd "$dir"
+}
+
## web search
## ws : string -> unit
ws() {
echo "${indent_unit}-->"
+ # TODO Populate pid->cmd dict from `ps -eo pid,comm` and lookup progs there
+ # since netstat -p output comes out truncated.
+
sudo -n netstat -tulnp \
| awk -v indent="${indent_unit}${indent_unit}" '
NR > 2 && ((/^tcp/ && proc = $7) || (/^udp/ && proc = $6)) {