bin: update sway_lock to use currently focused output
This commit is contained in:
		
							parent
							
								
									fad2310f6e
								
							
						
					
					
						commit
						d8a1632afc
					
				
					 1 changed files with 6 additions and 5 deletions
				
			
		|  | @ -1,10 +1,11 @@ | ||||||
| #!/bin/bash | #!/bin/bash | ||||||
| source $HOME/.config/sway/bin/sway_helpers | source $HOME/.config/sway/bin/sway_helpers | ||||||
| IMAGE=$HOME/.lockscreen.jpg | IMAGE=$HOME/.lockscreen.png | ||||||
| LOCK_IMAGE=$HOME/.config/sway/bin/lock.png | LOCK_IMAGE=$HOME/.config/sway/bin/lock.png | ||||||
|  | OUTPUT=$(swaymsg -t get_outputs -p | grep focused | cut -d " " -f 2) | ||||||
| MEDIA_APP=playerctl | MEDIA_APP=playerctl | ||||||
| SCROT_APP=grim | SCROT_APP=grim | ||||||
| SCROT_ARGS=" -t jpeg" | SCROT_ARGS=" -o $OUTPUT -t png" | ||||||
| LOCK_APP=swaylock | LOCK_APP=swaylock | ||||||
| LOCK_ARGS=" -f -F -e -c 000000 --indicator-radius 100 --indicator-thickness 20 -i $IMAGE" | LOCK_ARGS=" -f -F -e -c 000000 --indicator-radius 100 --indicator-thickness 20 -i $IMAGE" | ||||||
| INHIBIT_FILE=$HOME/.inhibit_lock | INHIBIT_FILE=$HOME/.inhibit_lock | ||||||
|  | @ -47,11 +48,11 @@ case "$1" in | ||||||
|     _on |     _on | ||||||
|     _screenshot |     _screenshot | ||||||
|     _lock |     _lock | ||||||
|     # _clean |     _clean | ||||||
|     ;; |     ;; | ||||||
|   lockonly) |   lockonly) | ||||||
|     _lock |     _lock | ||||||
|     # _clean |     _clean | ||||||
|     ;; |     ;; | ||||||
|   off) |   off) | ||||||
|     _screenshot |     _screenshot | ||||||
|  | @ -59,7 +60,7 @@ case "$1" in | ||||||
|     ;; |     ;; | ||||||
|   on) |   on) | ||||||
|     _on |     _on | ||||||
|     # _clean |     _clean | ||||||
|     ;; |     ;; | ||||||
|   screenshot) |   screenshot) | ||||||
|     _on |     _on | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Konstantin Koslowski
						Konstantin Koslowski