Skip to content

Commit f39ca8e

Browse files
authored
Merge branch 'dev' into dev
2 parents 95d5076 + b235cdf commit f39ca8e

File tree

24 files changed

+267
-160
lines changed

24 files changed

+267
-160
lines changed

CHANGELOG.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,13 @@ All notable changes to `HyDE` will be documented in this file.
44

55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to _Modified_ [CalVer](https://calver.org/). See [Versioning](https://github.com/HyDE-Project/HyDE/blob/master/RELEASE_POLICY.md#versioning-yymq) For more info
66

7-
## v25.8.1 (Unreleased)
7+
## v25.8.2
88

99
Big CHANGE in HyDE! We are now using `uwsm` for session management and app2unit for application management.
1010

11-
**PLEASE run install.sh again to upgrade and install missing dependencies!!!**
11+
**PLEASE run install.sh again to upgrade and install missing dependencies and REBOOT!**
12+
13+
In SDDM, please choose `Hyprland (UWSM Managed)` as your session. Or else you will handle the session yourself!
1214

1315
### Changed
1416

@@ -25,12 +27,14 @@ Big CHANGE in HyDE! We are now using `uwsm` for session management and app2unit
2527
- Package: UWSM as dependency for HyDE.
2628
- Core: app2unit.sh and xdg-terminal-exec as as static dependencies. These tools are not widely available and are not part of the core dependencies.
2729
- The ~/.config/xdg-terminals.list file is now used to determine which terminal to use.
30+
- Wallbash: Added spotify flatpak support
2831

2932
### Fixed
3033

3134
- Waybar: Some fixes for modules
3235
- Waybar: gpuinfo throws errors eg broken pipe
33-
- LibL Clean up variables that are using HYDE*, we will try to use the XDG\_* variables instead.
36+
- Lib: Clean up variables that are using HYDE*, we will try to use the XDG\_* variables instead.
37+
- Core: Fixed some issues with the theming script stack.
3438

3539
## v25.7.3
3640

Configs/.config/hyde/config.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
# Configuration file for HyDE
22
# Environment variables should be on top
33
# Updated config.toml file can be found at $HOME/.local/share/hyde/config.toml
4+
"$schema" = "https://raw.githubusercontent.com/HyDE-Project/HyDE/refs/heads/master/Configs/.local/share/hyde/schema/config.toml.json"

Configs/.config/hyde/wallbash/scripts/spotify.sh

Lines changed: 29 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -28,25 +28,29 @@ configure_spicetify() {
2828
spotify_conf=$(spicetify -c)
2929

3030
sed -i -e "/^prefs_path/ s+=.*$+= $HOME/.config/spotify/prefs+g" \
31-
-e "/^spotify_path/ s+=.*$+= $spotify_path+g" \
32-
-e "/^spotify_launch_flags/ s+=.*$+= $spotify_flags+g" "$spotify_conf"
31+
-e "/^spotify_path/ s+=.*$+= $spotify_path+g" \
32+
-e "/^spotify_launch_flags/ s+=.*$+= $spotify_flags+g" "$spotify_conf"
3333

34-
curl -L -o "${cache_dir}/landing/Spotify_Sleek.tar.gz" "https://github.com/prasanthrangan/hyprdots/raw/main/Source/arcs/Spotify_Sleek.tar.gz"
35-
tar -xzf "${cache_dir}/landing/Spotify_Sleek.tar.gz" -C ~/.config/spicetify/Themes/
34+
spicetify_themes_dir="$HOME/.config/spicetify/Themes"
35+
if [ ! -d "${spicetify_themes_dir}/Sleek" ]; then
36+
curl -L -o "${cache_dir}/landing/Spotify_Sleek.tar.gz" "https://github.com/HyDE-Project/HyDE/raw/master/Source/arcs/Spotify_Sleek.tar.gz"
37+
tar -xzf "${cache_dir}/landing/Spotify_Sleek.tar.gz" -C "$spicetify_themes_dir"
38+
fi
3639
spicetify backup apply
3740
spicetify config current_theme Sleek
3841
spicetify config color_scheme Wallbash
42+
spicetify config sidebar_config 0
3943
spicetify restore backup
4044
spicetify backup apply
4145
}
4246

4347
# Main script
44-
cacheDir="${cacheDir:-$XDG_CACHE_HOME/hyde}"
45-
shareDir=${XDG_DATA_HOME:-$HOME/.local/share}
48+
cacheDir="${cacheDir:-$XDG_CACHE_HOME/hyde}"
49+
shareDir=${XDG_DATA_HOME:-$HOME/.local/share}
4650

47-
if [ -n "${SPOTIFY_PATH}" ]; then
48-
spotify_path="${SPOTIFY_PATH}"
49-
cat <<EOF
51+
if [ -n "${SPOTIFY_PATH}" ]; then
52+
spotify_path="${SPOTIFY_PATH}"
53+
cat <<EOF
5054
[warning] using custom spotify path
5155
ensure to have proper permissions for ${SPOTIFY_PATH}
5256
run:
@@ -55,17 +59,24 @@ configure_spicetify() {
5559
5660
note: run with 'sudo' if only needed.
5761
EOF
58-
elif [ -f "${shareDir}/spotify-launcher/install/usr/bin/spotify" ]; then
59-
spotify_path="${shareDir}/spotify-launcher/install/usr/bin/spotify"
60-
elif [ -d /opt/spotify ]; then
61-
spotify_path='/opt/spotify'
62-
if [ ! -w "${spotify_path}" ] || [ ! -w "${spotify_path}/Apps" ]; then
63-
notify_and_set_permissions "${spotify_path}"
64-
fi
65-
fi
6662

67-
if (pkg_installed spotify && pkg_installed spicetify-cli) || [ -n "$spotify_path" ]; then
63+
elif [ -d "${XDG_DATA_HOME}/flatpak/app/com.spotify.Client/x86_64/stable/active/files/extra/share/spotify" ]; then
64+
spotify_path="${XDG_DATA_HOME}/flatpak/app/com.spotify.Client/x86_64/stable/active/files/extra/share/spotify"
65+
elif [ -d /var/lib/flatpak/app/com.spotify.Client/x86_64/stable/active/files/extra/share/spotify ]; then
66+
spotify_path='/var/lib/flatpak/app/com.spotify.Client/x86_64/stable/active/files/extra/share/spotify'
67+
elif [ -f "${shareDir}/spotify-launcher/install/usr/bin/spotify" ]; then
68+
spotify_path="${shareDir}/spotify-launcher/install/usr/share/spotify"
69+
elif [ -d /opt/spotify ]; then
70+
spotify_path='/opt/spotify'
71+
fi
6872

73+
if [ ! -w "${spotify_path}" ] || [ ! -w "${spotify_path}/Apps" ]; then
74+
notify_and_set_permissions "${spotify_path}"
75+
else
76+
printf "[info] using spotify path: %s\n" "${spotify_path}"
77+
fi
78+
79+
if (pkg_installed spotify && pkg_installed spicetify-cli) || [ -n "$spotify_path" ]; then
6980

7081
if [ "$(spicetify config | awk '{if ($1=="color_scheme") print $2}')" != "Wallbash" ] || [[ "${*}" == *"--reset"* ]]; then
7182
configure_spicetify "$spotify_path" "$cacheDir"

Configs/.config/xdg-terminals.list

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,4 @@
1+
# See https://github.com/Vladimir-csp/xdg-terminal-exec?tab=readme-ov-file#configuration
12
kitty.desktop
3+
Alacritty.desktop
4+
foot.desktop

Configs/.local/bin/hyde-shell

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -152,10 +152,10 @@ Restore Date: $HYDE_VERSION_LAST_CHECKED
152152
Last Commit Message: $HYDE_VERSION_COMMIT_MSG
153153
154154
Tools:
155-
hydectl: $(hydectl version || echo "hydectl not found")
156-
$(hyprland -v | head -n1 || echo "hyprland not found")
155+
hydectl: $(hydectl version 2>/dev/null || echo "hydectl not found")
156+
$(hyprland -v 2>/dev/null | head -n1 || echo "hyprland not found")
157157
$(if hyprctl_output=$(hyprctl version 2>/dev/null | head -n1); then echo "$hyprctl_output (Running Instance)"; else echo "hyprctl not found or not running"; fi)
158-
$(hyde-ipc --version || echo "hyde-ipc not found")
158+
$(hyde-ipc --version 2>/dev/null || echo "hyde-ipc not found")
159159
160160
161161
HyDE updates every friday, so please check for updates regularly.
@@ -393,7 +393,6 @@ generate_completions() {
393393
}
394394

395395
run_command() {
396-
python_activate
397396
# Convert to array, deduplicate, and filter out empty entries
398397
IFS=':' read -ra RAW_DIRS <<<"$HYDE_SCRIPTS_PATH"
399398
declare -A seen_dirs
@@ -415,6 +414,7 @@ run_command() {
415414
exec bash "$dir/${1}.sh" "${@:2}"
416415
# Try .py extension
417416
elif [[ -f "$dir/${1}.py" ]]; then
417+
python_activate
418418
exec python "$dir/${1}.py" "${@:2}"
419419
# Try exact name (executable)
420420
elif [[ -f "$dir/${1}" && -x "$dir/${1}" ]]; then
@@ -454,7 +454,6 @@ HYDE_SCRIPTS_PATH="${HYDE_SCRIPTS_PATH:-${XDG_CONFIG_HOME:-$HOME/.config}/hyde/s
454454

455455
export BIN_DIR LIB_DIR SHARE_DIR PATH HYDE_SCRIPTS_PATH
456456

457-
#? Handler for launchers that does not require other env variables
458457
#*--------------------------------------------------------------------------------
459458
if [[ "${1}" == "app" ]]; then
460459
export PATH="${HYDE_SCRIPTS_PATH}:${PATH}"

Configs/.local/lib/hyde/gnome-terminal

Lines changed: 0 additions & 23 deletions
This file was deleted.

Configs/.local/lib/hyde/hyde-launch.sh

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
#!/bin/bash
1+
#!/usr/bin/env bash
2+
3+
[[ "${HYDE_SHELL_INIT}" -ne 1 ]] && eval "$(hyde-shell init)"
24

35
# Declare an associative array for special cases
46
declare -A dict
@@ -103,20 +105,20 @@ main() {
103105

104106
[ -z "$mime_type" ] && {
105107
echo -e "Error: No matching MIME type found for $input\n"
106-
gtk-launch "${fallbackCmd}" || exit 1
108+
app2unit.sh "${fallbackCmd}" || exit 1
107109
}
108110

109111
local default_app
110112
default_app=$(xdg-mime query default "$mime_type")
111113
[ -z "$default_app" ] && {
112114
echo -e "Error: No default application found for $mime_type\n"
113-
gtk-launch "${fallbackCmd}" || exit 1
115+
app2unit.sh "${fallbackCmd}" || exit 1
114116
}
115117

116118
if [ "${std_only}" = true ]; then
117119
echo "${default_app}"
118120
else
119-
gtk-launch "${default_app}" || gtk-launch "${fallbackCmd}"
121+
app2unit.sh "${default_app}" || app2unit.sh "${fallbackCmd}"
120122
fi
121123
}
122124
main "$@"

Configs/.local/lib/hyde/theme.switch.sh

Lines changed: 53 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
[ -z "${HYDE_THEME}" ] && echo "ERROR: unable to detect theme" && exit 1
88
get_themes
9-
confDir="${XDG_CONFIG_HOME:-$(xdg-user-dir CONFIG)}"
9+
confDir="${XDG_CONFIG_HOME:-$HOME/.config}"
1010
#// define functions
1111

1212
Theme_Change() {
@@ -48,6 +48,44 @@ Notification font: ${NOTIFICATION_FONT}
4848
EOF
4949
}
5050

51+
load_hypr_variables() {
52+
local hypr_file="${1}"
53+
54+
#? Load theme specific variables
55+
eval "$(
56+
hyq "${hypr_file}" \
57+
--export env \
58+
-Q "\$GTK_THEME[string]" \
59+
-Q "\$ICON_THEME[string]" \
60+
-Q "\$CURSOR_THEME[string]" \
61+
-Q "\$CURSOR_SIZE[int]" \
62+
-Q "\$FONT[string]" \
63+
-Q "\$FONT_SIZE[int]" \
64+
-Q "\$FONT_STYLE[string]" \
65+
-Q "\$DOCUMENT_FONT[string]" \
66+
-Q "\$DOCUMENT_FONT_SIZE[int]" \
67+
-Q "\$MONOSPACE_FONT[string]" \
68+
-Q "\$MONOSPACE_FONT_SIZE[int]"
69+
)"
70+
71+
GTK_THEME=${__GTK_THEME:-$GTK_THEME}
72+
ICON_THEME=${__ICON_THEME:-$ICON_THEME}
73+
CURSOR_THEME=${__CURSOR_THEME:-$CURSOR_THEME}
74+
CURSOR_SIZE=${__CURSOR_SIZE:-$CURSOR_SIZE}
75+
TERMINAL=${__TERMINAL:-$TERMINAL}
76+
FONT=${__FONT:-$FONT}
77+
FONT_STYLE=${__FONT_STYLE:-''} # using hyprland this should be empty by default
78+
FONT_SIZE=${__FONT_SIZE:-$FONT_SIZE}
79+
DOCUMENT_FONT=${__DOCUMENT_FONT:-$DOCUMENT_FONT}
80+
DOCUMENT_FONT_SIZE=${__DOCUMENT_FONT_SIZE:-$DOCUMENT_FONT_SIZE}
81+
MONOSPACE_FONT=${__MONOSPACE_FONT:-$MONOSPACE_FONT}
82+
MONOSPACE_FONT_SIZE=${__MONOSPACE_FONT_SIZE:-$MONOSPACE_FONT_SIZE}
83+
BAR_FONT=${__BAR_FONT:-$BAR_FONT}
84+
MENU_FONT=${__MENU_FONT:-$MENU_FONT}
85+
NOTIFICATION_FONT=${__NOTIFICATION_FONT:-$NOTIFICATION_FONT}
86+
87+
}
88+
5189
sanitize_hypr_theme() {
5290
input_file="${1}"
5391
output_file="${2}"
@@ -131,37 +169,11 @@ if [[ -r "${HYPRLAND_CONFIG}" ]]; then
131169
[[ -n $HYPRLAND_INSTANCE_SIGNATURE ]] && hyprctl keyword misc:disable_autoreload 1 -q
132170
[[ -r "${HYDE_THEME_DIR}/hypr.theme" ]] && sanitize_hypr_theme "${HYDE_THEME_DIR}/hypr.theme" "${XDG_CONFIG_HOME}/hypr/themes/theme.conf"
133171

134-
eval "$(
135-
hyq "${HYDE_THEME_DIR}/hypr.theme" \
136-
--export env \
137-
-Q "\$GTK_THEME[string]" \
138-
-Q "\$ICON_THEME[string]" \
139-
-Q "\$CURSOR_THEME[string]" \
140-
-Q "\$CURSOR_SIZE[int]" \
141-
-Q "\$FONT[string]" \
142-
-Q "\$FONT_SIZE[int]" \
143-
-Q "\$FONT_STYLE[string]" \
144-
-Q "\$DOCUMENT_FONT[string]" \
145-
-Q "\$DOCUMENT_FONT_SIZE[int]" \
146-
-Q "\$MONOSPACE_FONT[string]" \
147-
-Q "\$MONOSPACE_FONT_SIZE[int]"
148-
)"
172+
#? Load theme specific variables
173+
load_hypr_variables "${HYDE_THEME_DIR}/hypr.theme"
149174

150-
GTK_THEME=${__GTK_THEME:-$GTK_THEME}
151-
ICON_THEME=${__ICON_THEME:-$ICON_THEME}
152-
CURSOR_THEME=${__CURSOR_THEME:-$CURSOR_THEME}
153-
CURSOR_SIZE=${__CURSOR_SIZE:-$CURSOR_SIZE}
154-
TERMINAL=${__TERMINAL:-$TERMINAL}
155-
FONT=${__FONT:-$FONT}
156-
FONT_STYLE=${__FONT_STYLE:-''} # using hyprland this should be empty by default
157-
FONT_SIZE=${__FONT_SIZE:-$FONT_SIZE}
158-
DOCUMENT_FONT=${__DOCUMENT_FONT:-$DOCUMENT_FONT}
159-
DOCUMENT_FONT_SIZE=${__DOCUMENT_FONT_SIZE:-$DOCUMENT_FONT_SIZE}
160-
MONOSPACE_FONT=${__MONOSPACE_FONT:-$MONOSPACE_FONT}
161-
MONOSPACE_FONT_SIZE=${__MONOSPACE_FONT_SIZE:-$MONOSPACE_FONT_SIZE}
162-
BAR_FONT=${__BAR_FONT:-$BAR_FONT}
163-
MENU_FONT=${__MENU_FONT:-$MENU_FONT}
164-
NOTIFICATION_FONT=${__NOTIFICATION_FONT:-$NOTIFICATION_FONT}
175+
#? Load User's hyprland overrides
176+
load_hypr_variables "${XDG_STATE_DIR:-$HOME/.local/state}/hyde/hyprland.conf"
165177

166178
fi
167179

@@ -235,7 +247,11 @@ else
235247
print_log -sec "theme" -stat "use" "'Wallbash-Gtk' as gtk4 theme"
236248
fi
237249
rm -rf "${confDir}/gtk-4.0"
238-
ln -s "${themesDir}/${gtk4Theme}/gtk-4.0" "${confDir}/gtk-4.0"
250+
if [ -d "${themesDir}/${gtk4Theme}/gtk-4.0" ]; then
251+
ln -s "${themesDir}/${gtk4Theme}/gtk-4.0" "${confDir}/gtk-4.0"
252+
else
253+
print_log -sec "theme" -warn "gtk4" "theme directory '${themesDir}/${gtk4Theme}/gtk-4.0' does not exist"
254+
fi
239255

240256
#// flatpak GTK
241257

@@ -296,6 +312,11 @@ if [ -f "$HOME/.Xdefaults" ]; then
296312
grep -q "^Xcursor\.size:" "$HOME/.Xdefaults" || echo "Xcursor.size: 30" >>"$HOME/.Xdefaults"
297313
fi
298314

315+
#? Workaround for gtk-4 having settings.ini!
316+
if [ -f "${confDir}/gtk-4.0/settings.ini" ]; then
317+
rm "${confDir}/gtk-4.0/settings.ini"
318+
fi
319+
299320
#// wallpaper
300321
export -f pkg_installed
301322

Configs/.local/lib/hyde/wallbash.hypr.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@
66

77
[[ "${HYDE_SHELL_INIT}" -ne 1 ]] && eval "$(hyde-shell init)"
88

9+
if [[ "${WALLBASH_STARTUP:-0}" -eq 1 ]]; then
10+
exit 0
11+
fi
12+
913
confDir="${confDir:-$XDG_CONFIG_HOME}"
1014
cacheDir="${cacheDir:-$XDG_CACHE_HOME/hyde}"
1115
HYDE_THEME="${HYDE_THEME:-}"

Configs/.local/lib/hyde/wallpaper.sh

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ options:
1414
-p, --previous Set previous wallpaper
1515
-r, --random Set random wallpaper
1616
-s, --set <file> Set specified wallpaper
17+
--start Start/apply current wallpaper to backend
1718
-g, --get Get current wallpaper of specified backend
1819
-o, --output <file> Copy current wallpaper to specified file
1920
--link Resolved the linked wallpaper according to the theme
@@ -191,7 +192,8 @@ main() {
191192
if [ -z "$wallpaper_backend" ] &&
192193
[ "$wallpaper_setter_flag" != "o" ] &&
193194
[ "$wallpaper_setter_flag" != "g" ] &&
194-
[ "$wallpaper_setter_flag" != "select" ]; then
195+
[ "$wallpaper_setter_flag" != "select" ] &&
196+
[ "$wallpaper_setter_flag" != "start" ]; then
195197
print_log -sec "wallpaper" -err "No backend specified"
196198
print_log -sec "wallpaper" " Please specify a backend, try '--backend swww'"
197199
print_log -sec "wallpaper" " See available commands: '--help | -h'"
@@ -240,6 +242,17 @@ main() {
240242
get_hashmap "${wallpaper_path}"
241243
Wall_Cache
242244
;;
245+
start)
246+
# Start/apply current wallpaper to backend
247+
if [ ! -e "${wallSet}" ]; then
248+
print_log -err "wallpaper" "No current wallpaper found: ${wallSet}"
249+
exit 1
250+
fi
251+
export WALLPAPER_RELOAD_ALL=0 WALLBASH_STARTUP=1
252+
current_wallpaper="$(realpath "${wallSet}")"
253+
get_hashmap "${current_wallpaper}"
254+
Wall_Cache
255+
;;
243256
g)
244257
if [ ! -e "${wallSet}" ]; then
245258
print_log -err "wallpaper" "Wallpaper not found: ${wallSet}"
@@ -301,7 +314,7 @@ if [ -z "${*}" ]; then
301314
fi
302315

303316
# Define long options
304-
LONGOPTS="link,global,select,json,next,previous,random,set:,backend:,get,output:,help,filetypes:"
317+
LONGOPTS="link,global,select,json,next,previous,random,set:,start,backend:,get,output:,help,filetypes:"
305318

306319
# Parse options
307320
PARSED=$(
@@ -353,6 +366,10 @@ while true; do
353366
wallpaper_path="${2}"
354367
shift 2
355368
;;
369+
--start)
370+
wallpaper_setter_flag=start
371+
shift
372+
;;
356373
-g | --get)
357374
wallpaper_setter_flag=g
358375
shift

0 commit comments

Comments
 (0)