Build with nix properly
This commit is contained in:
13
main.janet
13
main.janet
@@ -496,9 +496,10 @@
|
||||
(def ks [:tag-main :tag-offload :tags-other])
|
||||
(fn [seat binding]
|
||||
(def outputs (wm :outputs))
|
||||
(def tags (map |(table (seq [k :in ks] k ($ k))) outputs))
|
||||
(def tags (map |(tabseq [k :in ks] k ($ k)) outputs))
|
||||
(map (fn [out tags]
|
||||
(eachp [k tag] tags (put out k tag))) outputs [;(slice tags 1) (first tags)])))
|
||||
(eachp [k tag] tags (put out k tag))) outputs [;(slice tags 1) (first tags)])
|
||||
((action/focus-output :next) seat nil)))
|
||||
|
||||
(defn rule/pulldown []
|
||||
(fn [window]
|
||||
@@ -522,11 +523,11 @@
|
||||
|
||||
|
||||
(defn locked-screen []
|
||||
(print "Locked!")
|
||||
(def notifs-status (= 0 (os/execute ["dunstctl" "is-paused" "-e"] :p)))
|
||||
(os/execute ["dunstctl" "set-paused" "true"] :p)
|
||||
(os/execute ["pidwait" "swaylock"] :p) # Blocking is fine here -- we're locked
|
||||
(os/execute ["dunstctl" "set-paused" (if notifs-status "true" "false")] :p))
|
||||
(ev/spawn
|
||||
(os/execute ["pidwait" "swaylock"] :p)
|
||||
(os/execute ["dunstctl" "set-paused" (if notifs-status "true" "false")] :p)))
|
||||
|
||||
(defn lock-screen []
|
||||
(spawn "swaylock")
|
||||
@@ -583,7 +584,7 @@
|
||||
|
||||
|
||||
(defn startup []
|
||||
(spawn "pkill waybar && waybar")
|
||||
(spawn "pkill waybar; waybar")
|
||||
(spawn "kanshi")
|
||||
|
||||
(spawn "vesktop")
|
||||
|
||||
Reference in New Issue
Block a user