mirror of
https://github.com/CoolnsX/repos_scripts.git
synced 2025-12-20 07:15:20 +05:30
53 lines
888 B
Bash
53 lines
888 B
Bash
#!/bin/sh
|
|
|
|
#shellcheck disable=SC2086
|
|
|
|
menu_droid() {
|
|
fzf --prompt="$1" $2
|
|
}
|
|
|
|
menu_linux() {
|
|
bemenu --fn 'Cascadia Mono 15' -i -c -W "0.${3:-6}" -B 3 -l 25 -p "$1" --bdr="#$GLOBAL_ACCENT" --tf="#$GLOBAL_ACCENT" --hf="#$GLOBAL_ACCENT"
|
|
}
|
|
|
|
search_droid() {
|
|
printf "%s" "$1" && read -r query
|
|
}
|
|
|
|
search_linux() {
|
|
query=$(: | menu_linux "$1 ")
|
|
export query
|
|
}
|
|
|
|
torrent_linux() {
|
|
setsid -f "$TERMINAL" -e "$HOME/repos_scripts/torrent" "$1"
|
|
}
|
|
|
|
torrent_droid() {
|
|
"$HOME/.shortcuts/torrent" "$1"
|
|
}
|
|
|
|
info_droid() {
|
|
printf "\n\r\033[1;36m%s" "$1"
|
|
}
|
|
|
|
info_linux() {
|
|
notify-send "$1" -r '10' -i "$2" $3
|
|
}
|
|
|
|
error_droid() {
|
|
printf "\33[2K\r\033[1;31m%s" "$1"
|
|
}
|
|
|
|
error_linux() {
|
|
notify-send -u "critical" "$1" -r '10'
|
|
}
|
|
|
|
player_droid() {
|
|
am start --user 0 -a android.intent.action.VIEW -d "$1" -n is.xyz.mpv/.MPVActivity >/dev/null 2>&1
|
|
}
|
|
|
|
player_linux() {
|
|
mpv "$1" --force-media-title="$2"
|
|
}
|