Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

reworked systemd status

  • Loading branch information...
commit 55ceda73d54a28f8e2beab5edf91a4a7248de69b 1 parent 0b6df43
@graysky2 authored
Showing with 3 additions and 3 deletions.
  1. +3 −3 shell/.functions
View
6 shell/.functions
@@ -1,11 +1,11 @@
# systemd shortcuts
+listd() { [[ -d /etc/systemd/system/multi-user.target.wants ]] && ls -l /etc/systemd/system/multi-user.target.wants ; [[ -d /etc/systemd/system/default.target.wants ]] && ls -l /etc/systemd/system/default.target.wants; }
start() { sudo systemctl start $1.service ; sudo systemctl status $1.service; }
restart() { sudo systemctl restart $1.service ; sudo systemctl status $1.service; }
stop() { sudo systemctl stop $1.service ; sudo systemctl status $1.service; }
status() { sudo systemctl status $1.service; }
-enable() { sudo systemctl enable $1.service ; ls -l /etc/systemd/system/multi-user.target.wants; }
-disable() { sudo systemctl disable $1.service ; ls -l /etc/systemd/system/multi-user.target.wants; }
-listd() { ls -l /etc/systemd/system/multi-user.target.wants; }
+enable() { sudo systemctl enable $1.service ; listd; }
+disable() { sudo systemctl disable $1.service ; listd; }
# fix zsh annoying history behavior
h() { if [ -z "$*" ]; then history 1; else history 1 | egrep "$@"; fi; }
Please sign in to comment.
Something went wrong with that request. Please try again.