mirror of
https://github.com/caelestia-dots/cli.git
synced 2026-06-05 23:09:27 -05:00
feat: uwsm app -> app2unit
Also xdg-open -> app2unit
This commit is contained in:
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
. (dirname (status filename))/util.fish
|
. (dirname (status filename))/util.fish
|
||||||
|
|
||||||
install-deps git hyprland-git hyprpaper-git okolors-git imagemagick wl-clipboard fuzzel-git socat foot jq python xdg-user-dirs python-materialyoucolor-git
|
install-deps git hyprland-git hyprpaper-git okolors-git imagemagick wl-clipboard fuzzel-git socat foot jq python xdg-user-dirs python-materialyoucolor-git app2unit-git
|
||||||
install-optional-deps 'equibop-bin (discord client)' 'btop (system monitor)' 'wf-recorder (screen recorder)' 'grim (screenshot tool)' 'zen-browser (web browser)' 'spotify-adblock (music player)'
|
install-optional-deps 'equibop-bin (discord client)' 'btop (system monitor)' 'wf-recorder (screen recorder)' 'grim (screenshot tool)' 'zen-browser (web browser)' 'spotify-adblock (music player)'
|
||||||
|
|
||||||
set -l dist $C_DATA/scripts
|
set -l dist $C_DATA/scripts
|
||||||
|
|||||||
+1
-1
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
. (dirname (status filename))/util.fish
|
. (dirname (status filename))/util.fish
|
||||||
|
|
||||||
install-deps git dart-sass libastal-gjs-git libastal-meta npm curl libnotify ttf-material-symbols-variable-git ttf-jetbrains-mono-nerd ttf-rubik-vf pacman-contrib
|
install-deps git dart-sass libastal-gjs-git libastal-meta npm curl libnotify ttf-material-symbols-variable-git ttf-jetbrains-mono-nerd ttf-rubik-vf pacman-contrib app2unit-git
|
||||||
install-optional-deps 'uwsm (for systems using uwsm)' 'yay (AUR package management)' 'fd (launcher file search)' 'tod-bin (launcher todo action)' 'wl-clipboard (clipboard support)' 'foot (opening stuff in terminal)'
|
install-optional-deps 'uwsm (for systems using uwsm)' 'yay (AUR package management)' 'fd (launcher file search)' 'tod-bin (launcher todo action)' 'wl-clipboard (clipboard support)' 'foot (opening stuff in terminal)'
|
||||||
|
|
||||||
set -l shell $C_DATA/shell
|
set -l shell $C_DATA/shell
|
||||||
|
|||||||
+1
-1
@@ -83,7 +83,7 @@ if pgrep wf-recorder > /dev/null
|
|||||||
dbus-send --session --dest=org.freedesktop.FileManager1 --type=method_call /org/freedesktop/FileManager1 org.freedesktop.FileManager1.ShowItems array:string:"file://$new_recording_path" string:'' \
|
dbus-send --session --dest=org.freedesktop.FileManager1 --type=method_call /org/freedesktop/FileManager1 org.freedesktop.FileManager1.ShowItems array:string:"file://$new_recording_path" string:'' \
|
||||||
|| xdg-open (dirname $new_recording_path)
|
|| xdg-open (dirname $new_recording_path)
|
||||||
case 'save'
|
case 'save'
|
||||||
set -l save_file (uwsm app -- zenity --file-selection --save --title='Save As')
|
set -l save_file (app2unit -- zenity --file-selection --save --title='Save As')
|
||||||
test -n "$save_file" && mv $new_recording_path $save_file || warn 'No file selected'
|
test -n "$save_file" && mv $new_recording_path $save_file || warn 'No file selected'
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
|
|||||||
+3
-3
@@ -11,12 +11,12 @@ set -l action (notify-send -i 'image-x-generic-symbolic' -h "STRING:image-path:$
|
|||||||
'Screenshot taken' "Screenshot stored in $tmp_file and copied to clipboard")
|
'Screenshot taken' "Screenshot stored in $tmp_file and copied to clipboard")
|
||||||
switch $action
|
switch $action
|
||||||
case 'open'
|
case 'open'
|
||||||
uwsm app -- swappy -f $tmp_file & disown
|
app2unit -- swappy -f $tmp_file & disown
|
||||||
case 'save'
|
case 'save'
|
||||||
set -l save_file (uwsm app -- zenity --file-selection --save --title='Save As')
|
set -l save_file (app2unit -- zenity --file-selection --save --title='Save As')
|
||||||
test -z $save_file && exit 0
|
test -z $save_file && exit 0
|
||||||
if test -f $save_file
|
if test -f $save_file
|
||||||
uwsm app -- yad --image='abrt' --title='Warning!' --text-align='center' --buttons-layout='center' --borders=20 \
|
app2unit -- yad --image='abrt' --title='Warning!' --text-align='center' --buttons-layout='center' --borders=20 \
|
||||||
--text='<span size="x-large">Are you sure you want to overwrite this file?</span>' || exit 0
|
--text='<span size="x-large">Are you sure you want to overwrite this file?</span>' || exit 0
|
||||||
end
|
end
|
||||||
cp $tmp_file $save_file
|
cp $tmp_file $save_file
|
||||||
|
|||||||
+1
-1
@@ -13,7 +13,7 @@ function spawn-client -a selector spawn
|
|||||||
hyprctl -j clients | jq -e "first(.[] | select($selector))" > /dev/null
|
hyprctl -j clients | jq -e "first(.[] | select($selector))" > /dev/null
|
||||||
set -l stat $status
|
set -l stat $status
|
||||||
if test $stat != 0
|
if test $stat != 0
|
||||||
eval "uwsm app -- $spawn & disown"
|
eval "app2unit -- $spawn & disown"
|
||||||
end
|
end
|
||||||
test $stat != 0 # Exit 1 if already exists
|
test $stat != 0 # Exit 1 if already exists
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user