Skip to content

Instantly share code, notes, and snippets.

@Ikke
Created March 4, 2014 19:28
Show Gist options
  • Save Ikke/9353775 to your computer and use it in GitHub Desktop.
Save Ikke/9353775 to your computer and use it in GitHub Desktop.
Shortcuts for systemctl
#!/bin/bash
sys="sudo /usr/bin/systemctl"
case "$1" in
s) shift 1
$sys status $@
;;
o) shift 1
$sys stop $@
;;
a) shift 1
$sys start $@
;;
r) shift 1
$sys restart $@
;;
e) shift 1
$sys enable $@
;;
d) shift 1
$sys disable $@
;;
*) $sys $@
;;
esac
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment