04d08577e22a404df5b1c0fd1294e3f03f9d914b
- Author
- Robby Russell <robby@planetargon.com>
- Committer
- Robby Russell <robby@planetargon.com>
- Date
Message
Merge pull request #1336 from aelesbao/plugin-systemd
systemd plugin
Diff
1diff --git a/plugins/systemd/systemd.plugin.zsh b/plugins/systemd/systemd.plugin.zsh
2new file mode 100644
3index 0000000000000000000000000000000000000000..7d3db0f8e3bac444e6a31f24295e32f7fb317b0a
4--- /dev/null
5+++ b/plugins/systemd/systemd.plugin.zsh
6@@ -0,0 +1,11 @@
7+user_commands=(
8+ list-units is-active status show help list-unit-files
9+ is-enabled list-jobs show-environment)
10+
11+sudo_commands=(
12+ start stop reload restart try-restart isolate kill
13+ reset-failed enable disable reenable preset mask unmask
14+ link load cancel set-environment unset-environment)
15+
16+for c in $user_commands; do; alias sc-$c="systemctl $c"; done
17+for c in $sudo_commands; do; alias sc-$c="sudo systemctl $c"; done