Don Williams d298480443 feat: Hyprland 0.51.x upgrade tooling, central tags, docs update
Introduce focused Hyprland stack upgrade tooling and improve install
ordering for 0.51.x, with centralized version management and detailed
documentation for upgrading from 0.49/0.50.x to 0.51.1.

New scripts and modules
- update-hyprland.sh: Manage the Hyprland stack with:
  - --install / --dry-run build modes
  - --only and --skip for selective components
  - --with-deps to (re)install build deps
  - --set {KEY=TAG} and --restore tag backup support
  - --fetch-latest to pull latest GitHub release tags
  - --via-helper to delegate summary-only dry-runs
- dry-run-build.sh: Compile-only helper with summary output
- install-scripts/wayland-protocols-src.sh: Build wayland-protocols from
  source (>= 1.45) to satisfy Hyprland 0.51.x requirements

Core features
- Centralized tag management via hypr-tags.env; tags exported to all
  modules. Environment overrides remain first priority.
- Automatic dependency ordering for Hyprland 0.51.x:
  wayland-protocols-src → hyprland-protocols → hyprutils → hyprlang →
  aquamarine → hyprland
- Optional auto-fetch of latest tags on install runs that include
  hyprland (can be disabled via --no-fetch)
- Selective updates for targeted components and skip lists
- Dry-run mode to validate builds without installing

Installer integration
- install.sh reads hypr-tags.env and optionally refreshes tags.
- Ensures wayland-protocols-src is built before Hyprland.
- Maintains robust sequencing for the Hyprland stack.

Docs
- Debian-Hyprland-Install-Upgrade.md and .es.md:
  - Add explicit section: Upgrade 0.49/0.50.x → 0.51.1
  - Recommend: `./update-hyprland.sh --install --only hyprland`
  - Provide optional `--with-deps` and `--dry-run` flows
  - Add quick link anchor under Upgrade Workflows
- Clarify that full install via install.sh is not required for this
  upgrade unless optional modules need refresh or recovering from a
  partial/failed setup

Usage highlights
- Pin and upgrade to 0.51.1:
  ./update-hyprland.sh --set HYPRLAND=v0.51.1
  ./update-hyprland.sh --install --only hyprland
- Optional:
  ./update-hyprland.sh --with-deps --install --only hyprland
  ./update-hyprland.sh --dry-run --only hyprland

Notes
- Target OS remains Debian Trixie/SID; run as sudo-capable user (not
  root); ensure deb-src entries are enabled.
2025-10-09 16:51:11 -04:00

67 lines
2.7 KiB
Bash
Executable File

#!/bin/bash
# 💫 https://github.com/JaKooLit 💫 #
# Hyprland-Dots to download a specific release #
# Define the specific release version to download
specific_version="v2.3.16"
#specific_version="v2.3.3-Deb-Untu-Hyprland-0.41.2"
## WARNING: DO NOT EDIT BEYOND THIS LINE IF YOU DON'T KNOW WHAT YOU ARE DOING! ##
source "$(dirname "$(readlink -f "$0")")/Global_functions.sh"
printf "${NOTE} Downloading / Checking for existing Hyprland-Dots-${specific_version}.tar.gz...\n"
# Check if the specific release tarball exists
if [ -f "Hyprland-Dots-${specific_version}.tar.gz" ]; then
printf "${NOTE} Hyprland-Dots-${specific_version}.tar.gz found.\n"
echo -e "${OK} Hyprland-Dots-${specific_version}.tar.gz is already downloaded."
exit 0
fi
printf "${NOTE} Downloading the Hyprland-Dots-${specific_version} source code release...\n"
# Fetch the tag name for the specific release using the GitHub API
release_info=$(curl -s "https://api.github.com/repos/JaKooLit/Hyprland-Dots/releases/tags/${specific_version}")
if [ -z "$release_info" ]; then
echo -e "${ERROR} Unable to fetch information for release ${specific_version}." 2>&1 | tee -a "../Install-Logs/install-$(date +'%d-%H%M%S')_dotfiles.log"
exit 1
fi
# Get the tarball URL for the specific release
tarball_url=$(echo "$release_info" | grep "tarball_url" | cut -d '"' -f 4)
# Check if the URL is obtained successfully
if [ -z "$tarball_url" ]; then
echo -e "${ERROR} Unable to fetch the tarball URL for release ${specific_version}." 2>&1 | tee -a "../Install-Logs/install-$(date +'%d-%H%M%S')_dotfiles.log"
exit 1
fi
# Download the specific release source code tarball to the current directory
if curl -L "$tarball_url" -o "Hyprland-Dots-${specific_version}.tar.gz"; then
# Extract the contents of the tarball
tar -xzf "Hyprland-Dots-${specific_version}.tar.gz" || exit 1
# Delete existing Hyprland-Dots
rm -rf JaKooLit-Hyprland-Dots
# Identify the extracted directory
extracted_directory=$(tar -tf "Hyprland-Dots-${specific_version}.tar.gz" | grep -o '^[^/]\+' | uniq)
# Rename the extracted directory to JaKooLit-Hyprland-Dots
mv "$extracted_directory" JaKooLit-Hyprland-Dots || exit 1
cd "JaKooLit-Hyprland-Dots" || exit 1
# Set execute permission for copy.sh and execute it
chmod +x copy.sh
./copy.sh
echo -e "${OK} Hyprland-Dots-${specific_version} release downloaded, extracted, and processed successfully. Check JaKooLit-Hyprland-Dots directory for more detailed install logs" 2>&1 | tee -a "../Install-Logs/install-$(date +'%d-%H%M%S')_dotfiles.log"
else
echo -e "${ERROR} Failed to download Hyprland-Dots-${specific_version} release." 2>&1 | tee -a "../Install-Logs/install-$(date +'%d-%H%M%S')_dotfiles.log"
exit 1
fi
clear