aboutsummaryrefslogtreecommitdiff
path: root/sh
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2020-04-27 21:03:47 +1200
committerTom Ryder <tom@sanctum.geek.nz>2020-04-27 21:03:47 +1200
commite33f5665af536769b154ebcbbfae3b5bd2f7fff4 (patch)
tree230d00f96db8ccb968a05f23a2c73277deaa0d41 /sh
parentd5e6b1b19db9bda625343582a0c31c8bb7ce834f (diff)
downloaddotfiles-e33f5665af536769b154ebcbbfae3b5bd2f7fff4.tar.gz
dotfiles-e33f5665af536769b154ebcbbfae3b5bd2f7fff4.zip
Set systemctl editor to vi rather than ed
Diffstat (limited to 'sh')
-rw-r--r--sh/profile.d/systemd.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/sh/profile.d/systemd.sh b/sh/profile.d/systemd.sh
new file mode 100644
index 00000000..3c8bf04c
--- /dev/null
+++ b/sh/profile.d/systemd.sh
@@ -0,0 +1,4 @@
+# If systemctl is installed, use $VISUAL as its editor, not $EDITOR
+command -v systemctl >/dev/null 2>&1 || exit
+SYSTEMD_EDITOR=$VISUAL
+export SYSTEMD_EDITOR