mirror of
https://github.com/JaKooLit/Debian-Hyprland.git
synced 2025-12-21 10:20:12 +01:00
updated script
This commit is contained in:
parent
8833455ab6
commit
dd5070b374
25
install.sh
25
install.sh
@ -132,21 +132,30 @@ printf "\n"
|
|||||||
# Ensuring all in the scripts folder are made executable
|
# Ensuring all in the scripts folder are made executable
|
||||||
chmod +x install-scripts/*
|
chmod +x install-scripts/*
|
||||||
|
|
||||||
|
|
||||||
# enabling deb-src in /etc/apt/sources.list
|
# enabling deb-src in /etc/apt/sources.list
|
||||||
# Path to the sources.list file
|
# Path to the sources.list file
|
||||||
sources_list="/etc/apt/sources.list"
|
sources_list="/etc/apt/sources.list"
|
||||||
|
|
||||||
# Check if deb-src lines exist in the sources.list file
|
# Check if any lines starting with "# deb-src" exist
|
||||||
if grep -q "^deb-src" "$sources_list"; then
|
if grep -q "^# deb-src" "$sources_list"; then
|
||||||
echo "deb-src lines already exist in $sources_list."
|
echo "Found lines starting with '# deb-src' in $sources_list."
|
||||||
else
|
else
|
||||||
# Add deb-src lines if they don't exist
|
# Remove the '#' from the first line starting with '#deb-src'
|
||||||
echo "deb-src lines not found in $sources_list. Adding one..."
|
echo "No lines starting with '# deb-src' found in $sources_list. Removing '#' from the first such line..."
|
||||||
sudo sed -i '/^deb /s/^/#/' "$sources_list"
|
sudo sed -i '0,/^#deb-src/ s/^# //' "$sources_list"
|
||||||
sudo sed -i '/^# deb-src/ s/^# //' "$sources_list"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Check if any lines starting with "deb" exist
|
||||||
|
if grep -q "^deb" "$sources_list"; then
|
||||||
|
echo "Found lines starting with 'deb' in $sources_list."
|
||||||
|
else
|
||||||
|
# Remove the '#' from lines starting with '# deb'
|
||||||
|
echo "No lines starting with 'deb' found in $sources_list. Removing '#' from lines starting with '# deb'..."
|
||||||
|
sudo sed -i '/^# deb/ s/^# //' "$sources_list"
|
||||||
|
fi
|
||||||
|
|
||||||
|
sudo apt update
|
||||||
|
|
||||||
# Install hyprland packages
|
# Install hyprland packages
|
||||||
execute_script "00-dependencies.sh"
|
execute_script "00-dependencies.sh"
|
||||||
execute_script "00-hypr-pkgs.sh"
|
execute_script "00-hypr-pkgs.sh"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user