Alex Balgavy

Just some stuff about me.

Here's my dotfiles repository.

Check out my blog.

My keys: PGP, SSH

My crypto wallets (BTC, XMR)

Keyboard shortcuts

Directory stack

exec builtin

usage:

examples:

exec 1> >(lolcat >&2)   # make shell redirect stdout to process lolcat,
                        # which redirects to stderr
exec 3< input.txt        # create a new file descriptor, reading from input.txt
read LINE <&3            # read from the file descriptor into LINE
exec 3<&-                # close the file descriptor
exec 4> output.log       # create a new file descriptor for writing to output.log
echo “foo” >&4           # write “foo” to file descriptor 4 (output.log)
exec 4>&-                # close the file descriptor
echo “foo bar” > file    # write “foo bar” to file
exec 5<>file             # open file for rw on file descriptor 5
read -n 3 var <&5        # read 3 characters from file descriptor 5 into var
echo "Hello" >&5         # write "Hello" into the file
exec 5>&-                # close the file for writing
exec 5<&-                # close the file for reading

Change keybindings

Misc sets

Variable expansion

Reusing previously typed stuff

Redirection

order matters, creating a new redirection essentially duplicates the file descriptor (e.g. “command > file 2>&1” != “command 2>&1 > file“

ffmpeg

bc