remove unused configs and scripts
This commit is contained in:
parent
17da741667
commit
93bca05bc9
|
@ -1,108 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
## Author : Aditya Shakya (adi1090x)
|
||||
## Github : @adi1090x
|
||||
#
|
||||
## Rofi : Power Menu
|
||||
|
||||
# CMDs
|
||||
uptime="`uptime -p | sed -e 's/up //g'`"
|
||||
host=`cat /etc/hostname`
|
||||
|
||||
# Options
|
||||
hibernate=''
|
||||
shutdown='⏼'
|
||||
reboot=''
|
||||
lock=''
|
||||
suspend=''
|
||||
logout=''
|
||||
yes=''
|
||||
no=''
|
||||
|
||||
# Rofi CMD
|
||||
rofi_cmd() {
|
||||
rofi -dmenu \
|
||||
-p "$USER@$host" \
|
||||
-mesg "Uptime: $uptime" \
|
||||
-theme ~/.config/rofi/powermenu.rasi
|
||||
}
|
||||
|
||||
# Confirmation CMD
|
||||
confirm_cmd() {
|
||||
rofi -theme-str 'window {location: center; anchor: center; fullscreen: false; width: 350px;}' \
|
||||
-theme-str 'mainbox {children: [ "message", "listview" ];}' \
|
||||
-theme-str 'listview {columns: 2; lines: 1;}' \
|
||||
-theme-str 'element-text {horizontal-align: 0.5;}' \
|
||||
-theme-str 'textbox {horizontal-align: 0.5;}' \
|
||||
-dmenu \
|
||||
-p 'Confirmation' \
|
||||
-mesg 'Are you Sure?' \
|
||||
-theme ~/.config/rofi/powermenu.rasi
|
||||
}
|
||||
|
||||
# Ask for confirmation
|
||||
confirm_exit() {
|
||||
echo -e "$yes\n$no" | confirm_cmd
|
||||
}
|
||||
|
||||
# Pass variables to rofi dmenu
|
||||
run_rofi() {
|
||||
echo -e "$lock\n$logout\n$reboot\n$shutdown" | rofi_cmd
|
||||
}
|
||||
|
||||
# Execute Command
|
||||
run_cmd() {
|
||||
selected="$(confirm_exit)"
|
||||
if [[ "$selected" == "$yes" ]]; then
|
||||
if [[ $1 == '--shutdown' ]]; then
|
||||
systemctl poweroff
|
||||
elif [[ $1 == '--reboot' ]]; then
|
||||
systemctl reboot
|
||||
elif [[ $1 == '--hibernate' ]]; then
|
||||
systemctl hibernate
|
||||
elif [[ $1 == '--suspend' ]]; then
|
||||
systemctl suspend
|
||||
elif [[ $1 == '--logout' ]]; then
|
||||
if [[ "$DESKTOP_SESSION" == 'openbox' ]]; then
|
||||
openbox --exit
|
||||
elif [[ "$DESKTOP_SESSION" == 'bspwm' ]]; then
|
||||
bspc quit
|
||||
elif [[ "$DESKTOP_SESSION" == 'i3' ]]; then
|
||||
i3-msg exit
|
||||
elif [[ "$DESKTOP_SESSION" == 'plasma' ]]; then
|
||||
qdbus org.kde.ksmserver /KSMServer logout 0 0 0
|
||||
elif [[ "$XDG_CURRENT_DESKTOP" == 'Hyprland' ]]; then
|
||||
hyprctl dispatch exit
|
||||
fi
|
||||
fi
|
||||
else
|
||||
exit 0
|
||||
fi
|
||||
}
|
||||
|
||||
# Actions
|
||||
chosen="$(run_rofi)"
|
||||
case ${chosen} in
|
||||
$shutdown)
|
||||
run_cmd --shutdown
|
||||
;;
|
||||
$reboot)
|
||||
run_cmd --reboot
|
||||
;;
|
||||
$hibernate)
|
||||
run_cmd --hibernate
|
||||
;;
|
||||
$lock)
|
||||
if [[ -x '/usr/bin/betterlockscreen' ]]; then
|
||||
betterlockscreen -l
|
||||
elif [[ -x '/usr/bin/i3lock' ]]; then
|
||||
i3lock
|
||||
fi
|
||||
;;
|
||||
$suspend)
|
||||
run_cmd --suspend
|
||||
;;
|
||||
$logout)
|
||||
run_cmd --logout
|
||||
;;
|
||||
esac
|
|
@ -1,54 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
printf "%s\n" "Currently disabled"
|
||||
|
||||
{ [[ -z $1 ]] || [[ -z $2 ]]; } && {
|
||||
printf "%s\n" "Usage: setwal /path/to/wallpaper mode"
|
||||
exit 1
|
||||
}
|
||||
|
||||
[ ! -f "$1" ] && {
|
||||
printf "File not found: %s\n" "$1"
|
||||
exit 2
|
||||
}
|
||||
|
||||
yes | ffmpeg -i "$1" ~/.config/hypr/wallpaper.png >/dev/null 2>&1 || {
|
||||
printf "Failed to copy wallpaper from %s\n" "$1"
|
||||
exit 3
|
||||
}
|
||||
|
||||
{
|
||||
hyprctl hyprpaper unload all >/dev/null
|
||||
hyprctl hyprpaper preload ~/.config/hypr/wallpaper.png >/dev/null
|
||||
hyprctl hyprpaper wallpaper ",~/.config/hypr/wallpaper.png" >/dev/null
|
||||
} &
|
||||
|
||||
update() {
|
||||
makoctl reload
|
||||
}
|
||||
|
||||
dark() {
|
||||
matugen image ~/.config/hypr/wallpaper.png -c ~/.config/hypr/matugen/config.toml -m dark
|
||||
gsettings set org.gnome.desktop.interface gtk-theme "adw-gtk3-not-exist" >/dev/null
|
||||
sleep 0.1
|
||||
gsettings set org.gnome.desktop.interface gtk-theme "adw-gtk3-dark" >/dev/null
|
||||
gsettings set org.gnome.desktop.interface color-scheme 'prefer-dark'
|
||||
update
|
||||
}
|
||||
|
||||
light() {
|
||||
matugen image ~/.config/hypr/wallpaper.png -c ~/.config/hypr/matugen/config.toml -m light
|
||||
gsettings set org.gnome.desktop.interface gtk-theme "adw-gtk3-not-exist" >/dev/null
|
||||
sleep 0.1
|
||||
gsettings set org.gnome.desktop.interface gtk-theme "adw-gtk3" >/dev/null
|
||||
gsettings set org.gnome.desktop.interface color-scheme 'prefer-light'
|
||||
update
|
||||
}
|
||||
|
||||
case "$2" in
|
||||
"light")
|
||||
light
|
||||
;;
|
||||
*)
|
||||
dark
|
||||
;;
|
||||
esac
|
|
@ -1,65 +0,0 @@
|
|||
{
|
||||
"debug": {
|
||||
"disable_auto_focus": false,
|
||||
"enable_logging": false
|
||||
},
|
||||
"theme": {
|
||||
"colors": {
|
||||
"border": "#89b4fa",
|
||||
"item_bg": "#00000000",
|
||||
"item_bg_hover": "#89b4faef",
|
||||
"item_bg_selected": "#89b4faef",
|
||||
"item_description": "#bac2de",
|
||||
"item_description_selected": "#181825",
|
||||
"item_name": "#cdd6f4",
|
||||
"item_name_selected": "#1e1e2e",
|
||||
"item_path": "#a6adc8",
|
||||
"item_path_selected": "#181825",
|
||||
"search_bg": "#181825aa",
|
||||
"search_bg_focused": "#89b4fa",
|
||||
"search_caret": "#cdd6f4",
|
||||
"search_text": "#cdd6f4",
|
||||
"window_bg": "#1e1e2e88"
|
||||
},
|
||||
"corners": {
|
||||
"list_item": 8,
|
||||
"search": 8,
|
||||
"window": 12
|
||||
},
|
||||
"spacing": {
|
||||
"item_margin": 8,
|
||||
"item_padding": 2,
|
||||
"search_margin": 9,
|
||||
"search_padding": 9
|
||||
},
|
||||
"typography": {
|
||||
"item_description_size": 12,
|
||||
"item_name_size": 14,
|
||||
"item_path_font_family": "JetBrainsMono Nerd Font Mono",
|
||||
"item_path_size": 12,
|
||||
"search_font_size": 16
|
||||
}
|
||||
},
|
||||
"window": {
|
||||
"anchor": "center",
|
||||
"border_width": 3,
|
||||
"custom_navigate_keys": {
|
||||
"delete_word": "h",
|
||||
"down": "j",
|
||||
"up": "k"
|
||||
},
|
||||
"height": 400,
|
||||
"margin_bottom": 20,
|
||||
"margin_left": 0,
|
||||
"margin_right": 0,
|
||||
"margin_top": 0,
|
||||
"max_entries": 50,
|
||||
"show_border": true,
|
||||
"show_descriptions": true,
|
||||
"show_icons": true,
|
||||
"show_paths": true,
|
||||
"show_search": true,
|
||||
"use_gtk_colors": false,
|
||||
"width": 600
|
||||
}
|
||||
}
|
|
@ -1,4 +0,0 @@
|
|||
[Settings]
|
||||
folder = /mnt/data/Wallpapers/unsorted
|
||||
backend = hyprpaper
|
||||
last_wallpaper = /mnt/data/Wallpapers/unsorted/neon-dunes-8k.jpg
|
Loading…
Reference in a new issue