58d904a28960f6962eb27a6105e83d57cb553aba
- Author
- Augusto Rocha Elesbão <aelesbao@gmail.com>
- Committer
- Augusto Rocha Elesbão <aelesbao@gmail.com>
- Date
Message
Added systemd plugin with aliases for systemctl commands.
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