diff options
author | EuAndreh <eu@euandre.org> | 2022-11-28 08:30:19 -0300 |
---|---|---|
committer | EuAndreh <eu@euandre.org> | 2022-11-28 08:30:19 -0300 |
commit | 7b98b5f8985f8227c758a6181963204c905fef92 (patch) | |
tree | f6a6b2abee6709d45748498140f9557ef28b5db3 | |
parent | etc/sh/cronjob.sh: Add $(hostname) to cronjob subject (diff) | |
download | dotfiles-7b98b5f8985f8227c758a6181963204c905fef92.tar.gz dotfiles-7b98b5f8985f8227c758a6181963204c905fef92.tar.xz |
etc/sh/rc: Allow f(1) to work without any arguments
-rw-r--r-- | etc/sh/rc | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -271,8 +271,8 @@ f() { if [ -n "$file" ]; then # shellcheck disable=2068 history -s f "$@" - history -s "$1" "$file" - "$1" "$file" + history -s "${1:-$EDITOR}" "$file" + "${1:-$EDITOR}" "$file" fi } |