diff options
| author | Don Williams <don.e.williams@gmail.com> | 2026-08-15 06:20:10 -0400 |
|---|---|---|
| committer | Pinapelz <yukais@pinapelz.com> | 2026-08-29 21:41:34 -0700 |
| commit | b65377decf99a4d53583ceb0f277f17af1671267 (patch) | |
| tree | faadf6bdd1945a2396b37a8cea8abaeb9e558fc6 /copy.sh | |
| parent | 3f587a40f6dc7c162bd30e13d27b5ffe89bd73b9 (diff) | |
Copy.sh wasn't setting LUA as default on new install
Signed-off-by: Don Williams <don.e.williams@gmail.com>
On branch development
Your branch is up to date with 'origin/development'.
Changes to be committed:
modified: copy.sh
modified: scripts/lib_copy.sh
Diffstat (limited to 'copy.sh')
| -rwxr-xr-x | copy.sh | 22 |
1 files changed, 11 insertions, 11 deletions
@@ -257,24 +257,24 @@ version_gte() { # Parse installed Hyprland version (e.g. 0.55.4) from hyprctl/Hyprland. get_hyprland_version() { local ver="" - local raw="" + local full_output="" if command -v hyprctl >/dev/null 2>&1; then - raw="$(hyprctl version 2>/dev/null | head -n1 || true)" + full_output="$(hyprctl version 2>/dev/null || true)" fi - if [ -z "$raw" ] && command -v Hyprland >/dev/null 2>&1; then - raw="$(Hyprland --version 2>/dev/null | head -n1 || true)" + if [ -z "$full_output" ] && command -v Hyprland >/dev/null 2>&1; then + full_output="$(Hyprland --version 2>/dev/null || true)" fi - if [ -z "$raw" ] && command -v hyprland >/dev/null 2>&1; then - raw="$(hyprland --version 2>/dev/null | head -n1 || true)" + if [ -z "$full_output" ] && command -v hyprland >/dev/null 2>&1; then + full_output="$(hyprland --version 2>/dev/null || true)" fi # Prefer Tag: vX.Y.Z when present in full output - if command -v hyprctl >/dev/null 2>&1; then - ver="$(hyprctl version 2>/dev/null | sed -n 's/^Tag: v\([0-9][0-9.]*\).*/\1/p' | head -n1 || true)" - fi - if [ -z "$ver" ] && [ -n "$raw" ]; then - ver="$(printf '%s\n' "$raw" | sed -n 's/.*[Hh]yprland[[:space:]]\+v\?\([0-9][0-9.]*\).*/\1/p' | head -n1)" + ver="$(printf '%s\n' "$full_output" | sed -n 's/^Tag: v\([0-9][0-9.]*\).*/\1/p' | head -n1 || true)" + + # Fallback to matching 'Hyprland v0.X.Y' or 'Hyprland 0.X.Y' anywhere in full output + if [ -z "$ver" ] && [ -n "$full_output" ]; then + ver="$(printf '%s\n' "$full_output" | sed -n 's/.*[Hh]yprland[[:space:]]\+v\?\([0-9][0-9.]*\).*/\1/p' | head -n1 || true)" fi printf '%s' "$ver" |
