aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--etc/sh/rc4
1 files changed, 2 insertions, 2 deletions
diff --git a/etc/sh/rc b/etc/sh/rc
index 4a79482..b15ef9d 100644
--- a/etc/sh/rc
+++ b/etc/sh/rc
@@ -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
}