From 9afa4c8e632c7fb4eabc1f7025f40c0274057f04 Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Sat, 29 Oct 2016 19:03:32 -0700 Subject: [PATCH] Revert "[Linux] Taffybar now managed by xmonad instead of systemd" This reverts commit 04ae4335f206b708d757593f0cfee96a7316dc4b. --- dotfiles/config/systemd/user/dunst.service | 1 + dotfiles/config/systemd/user/keepassx.service | 1 + dotfiles/config/systemd/user/nm-applet.service | 1 + dotfiles/config/systemd/user/pasystray.service | 1 + dotfiles/config/systemd/user/screencloud.service | 1 + dotfiles/config/systemd/user/taffybar.service | 10 ++++++++++ dotfiles/config/systemd/user/udiskie.service | 1 + dotfiles/xmonad/xmonad.hs | 7 +++---- 8 files changed, 19 insertions(+), 4 deletions(-) create mode 100644 dotfiles/config/systemd/user/taffybar.service diff --git a/dotfiles/config/systemd/user/dunst.service b/dotfiles/config/systemd/user/dunst.service index e57e4aad..18620aef 100644 --- a/dotfiles/config/systemd/user/dunst.service +++ b/dotfiles/config/systemd/user/dunst.service @@ -1,5 +1,6 @@ [Unit] Description=Dunst +Requires=taffybar.service After=taffybar.service [Service] diff --git a/dotfiles/config/systemd/user/keepassx.service b/dotfiles/config/systemd/user/keepassx.service index 94ec40fa..1a91776d 100644 --- a/dotfiles/config/systemd/user/keepassx.service +++ b/dotfiles/config/systemd/user/keepassx.service @@ -1,5 +1,6 @@ [Unit] Description=KeePassX +Requires=taffybar.service After=taffybar.service [Service] diff --git a/dotfiles/config/systemd/user/nm-applet.service b/dotfiles/config/systemd/user/nm-applet.service index 851586d2..732809d4 100644 --- a/dotfiles/config/systemd/user/nm-applet.service +++ b/dotfiles/config/systemd/user/nm-applet.service @@ -1,5 +1,6 @@ [Unit] Description=NM Applet +Requires=taffybar.service After=taffybar.service [Service] diff --git a/dotfiles/config/systemd/user/pasystray.service b/dotfiles/config/systemd/user/pasystray.service index f7976cdc..3cf27764 100644 --- a/dotfiles/config/systemd/user/pasystray.service +++ b/dotfiles/config/systemd/user/pasystray.service @@ -1,5 +1,6 @@ [Unit] Description=Pulse Audio System Tray +Requires=taffybar.service After=taffybar.service [Service] diff --git a/dotfiles/config/systemd/user/screencloud.service b/dotfiles/config/systemd/user/screencloud.service index 4149c6ee..9ef86b13 100644 --- a/dotfiles/config/systemd/user/screencloud.service +++ b/dotfiles/config/systemd/user/screencloud.service @@ -1,5 +1,6 @@ [Unit] Description=ScreenCloud +Requires=taffybar.service After=taffybar.service [Service] diff --git a/dotfiles/config/systemd/user/taffybar.service b/dotfiles/config/systemd/user/taffybar.service new file mode 100644 index 00000000..30210c3a --- /dev/null +++ b/dotfiles/config/systemd/user/taffybar.service @@ -0,0 +1,10 @@ +[Unit] +Description=taffybar + +[Service] +Type=simple +ExecStart=/usr/bin/env taffybar +ExecStop=/usr/bin/pkill taffybar + +[Install] +WantedBy=wm.target diff --git a/dotfiles/config/systemd/user/udiskie.service b/dotfiles/config/systemd/user/udiskie.service index 7f9be0a4..6efc8a4c 100644 --- a/dotfiles/config/systemd/user/udiskie.service +++ b/dotfiles/config/systemd/user/udiskie.service @@ -1,5 +1,6 @@ [Unit] Description=udiskie +Requires=taffybar.service After=taffybar.service [Service] diff --git a/dotfiles/xmonad/xmonad.hs b/dotfiles/xmonad/xmonad.hs index 0c979323..2043d3e9 100644 --- a/dotfiles/xmonad/xmonad.hs +++ b/dotfiles/xmonad/xmonad.hs @@ -65,9 +65,7 @@ virtualClasses = [(hangoutsSelector, "Hangouts")] -- Startup -myStartup = do - spawn "taffybar" - spawn "systemctl --user start wm.target" +myStartup = spawn "systemctl --user start wm.target" -- Manage @@ -206,7 +204,8 @@ addKeys conf@XConfig {modMask = modm} = , ((modm .|. shiftMask, xK_p), spawn "rofi -show run") , ((modm, xK_g), actionMenu myWindowBringerConfig greedyFocusWindow) , ((modm, xK_b), bringMenuConfig myWindowBringerConfig) - , ((modm .|. controlMask, xK_t), spawn "restart.sh taffybar") + , ((modm .|. controlMask, xK_t), spawn + "systemctl --user restart taffybar.service") , ((modm, xK_v), spawn "copyq paste") , ((modm, xK_s), swapNextScreen) , ((modm .|. controlMask, xK_space), sendMessage $ JumpToLayout "Full")