Compare commits
2 Commits
2cb03748d0
...
96cd1d5613
Author | SHA1 | Date | |
---|---|---|---|
96cd1d5613 | |||
8bce55645f |
@ -48,7 +48,7 @@ These lovely utilities are often already available on many `sway` setups.
|
||||
order += "run_watch screenrecord"
|
||||
|
||||
run_watch screenrecord {
|
||||
pidfile = "/var/run/user/1000/screenrecord.pid"
|
||||
pidfile = "/run/user/1000/screenrecord.pid"
|
||||
format = "🎥"
|
||||
format_down = ""
|
||||
}
|
||||
|
@ -23,11 +23,11 @@
|
||||
#
|
||||
# Author Lorenzo Cogotti, The DoubleFourteen Code Forge
|
||||
|
||||
pidfile="/var/run/user/$(id -u)/screenrecord.pid"
|
||||
pidfile="$XDG_RUNTIME_DIR/screenrecord.pid"
|
||||
filename="$(xdg-user-dir VIDEOS)/ScreenCast_$(date +%F_%T).mp4"
|
||||
|
||||
isrunning() {
|
||||
pid=$(cat "$pidfile" 2>/dev/null)
|
||||
pid=$(2>/dev/null <"$pidfile")
|
||||
test $? && kill -s 0 -- "$pid" 2>/dev/null
|
||||
return $?
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user