From 0cc69f13c2355831e8f07962c072c09ca35fd5f3 Mon Sep 17 00:00:00 2001 From: Jouke Witteveen Date: Tue, 6 Jan 2015 19:31:39 +0100 Subject: Add edit subcommand to netctl --- src/netctl.in | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/netctl.in b/src/netctl.in index b66cf71..2953ecf 100644 --- a/src/netctl.in +++ b/src/netctl.in @@ -20,8 +20,9 @@ Commands: status [PROFILE] Show runtime status of a profile enable [PROFILE] Enable the systemd unit for a profile disable [PROFILE] Disable the systemd unit for a profile - is-enabled [PROFILE] Check whether a profile is enabled reenable [PROFILE] Reenable the systemd unit for a profile + is-enabled [PROFILE] Check whether a profile is enabled + edit [PROFILE] Edit a profile END } @@ -180,6 +181,8 @@ case $# in if sd_booted; then systemctl daemon-reload fi;; + edit) + exec ${EDITOR:-nano} "$PROFILE_DIR/$2";; *) exit_error "$(usage)";; esac;; -- cgit v1.2.3-24-g4f1b