mirror of
https://github.com/JaKooLit/Debian-Hyprland.git
synced 2025-12-21 18:20:13 +01:00
updated install_package module.Corrected nvidia.sh
This commit is contained in:
parent
013a465af5
commit
16d0cab62c
@ -88,6 +88,8 @@ sudo ninja -C build install
|
||||
- [X] ~~Use kitty in favor of foot~~ - Dropped the idea of kitty. Kitty is using twice memory compared to foot.
|
||||
|
||||
### ❗ some known issues
|
||||
- Currently SDDM theme that I have set is broken... currently investigating
|
||||
|
||||
- reports from members of my discord, states that some users of nvidia are getting stuck on sddm login. credit to @Kenni Fix stated was
|
||||
```
|
||||
while in sddm press ctrl+alt+F2 or F3
|
||||
|
||||
@ -121,7 +121,9 @@ install_package() {
|
||||
else
|
||||
# Package not installed
|
||||
echo -e "${NOTE} Installing $1 ..."
|
||||
if sudo apt-get install -y "$1" 2>&1 | tee -a "$LOG"; then
|
||||
sudo apt-get install -y "$1" >> "$LOG" 2>&1
|
||||
# Check if the package was installed successfully
|
||||
if dpkg -l | grep -q -w "$1"; then
|
||||
echo -e "\e[1A\e[K${OK} $1 was installed."
|
||||
else
|
||||
# Something is missing, exiting to review the log
|
||||
|
||||
@ -81,7 +81,9 @@ install_package() {
|
||||
else
|
||||
# Package not installed
|
||||
echo -e "${NOTE} Installing $1 ..."
|
||||
if sudo apt-get install -y "$1" 2>&1 | tee -a "$LOG"; then
|
||||
sudo apt-get install -y "$1" >> "$LOG" 2>&1
|
||||
# Check if the package was installed successfully
|
||||
if dpkg -l | grep -q -w "$1"; then
|
||||
echo -e "\e[1A\e[K${OK} $1 was installed."
|
||||
else
|
||||
# Something is missing, exiting to review the log
|
||||
|
||||
@ -38,7 +38,9 @@ install_package() {
|
||||
else
|
||||
# Package not installed
|
||||
echo -e "${NOTE} Installing $1 ..."
|
||||
if sudo apt-get install -y "$1" 2>&1 | tee -a "$LOG"; then
|
||||
sudo apt-get install -y "$1" >> "$LOG" 2>&1
|
||||
# Check if the package was installed successfully
|
||||
if dpkg -l | grep -q -w "$1"; then
|
||||
echo -e "\e[1A\e[K${OK} $1 was installed."
|
||||
else
|
||||
# Something is missing, exiting to review the log
|
||||
|
||||
@ -31,7 +31,9 @@ install_package() {
|
||||
else
|
||||
# Package not installed
|
||||
echo -e "${NOTE} Installing $1 ..."
|
||||
if sudo apt-get install -y "$1" 2>&1 | tee -a "$LOG"; then
|
||||
sudo apt-get install -y "$1" >> "$LOG" 2>&1
|
||||
# Check if the package was installed successfully
|
||||
if dpkg -l | grep -q -w "$1"; then
|
||||
echo -e "\e[1A\e[K${OK} $1 was installed."
|
||||
else
|
||||
# Something is missing, exiting to review the log
|
||||
|
||||
@ -32,6 +32,17 @@ LOG="install-$(date +%d-%H%M%S)_nvidia.log"
|
||||
|
||||
set -e
|
||||
|
||||
## adding the deb source for nvidia driver
|
||||
# Create a backup of the sources.list file
|
||||
sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup 2>&1 | tee -a "$LOG"
|
||||
|
||||
# Add the comment and repository entry to sources.list
|
||||
echo "## for nvidia" | sudo tee -a /etc/apt/sources.list 2>&1 | tee -a "$LOG"
|
||||
echo "deb http://deb.debian.org/debian/ trixie main contrib non-free non-free-firmware" | sudo tee -a /etc/apt/sources.list 2>&1 | tee -a "$LOG"
|
||||
|
||||
# Update the package list
|
||||
sudo apt update
|
||||
|
||||
# Function for installing packages on Debian/Ubuntu
|
||||
install_package() {
|
||||
# Checking if package is already installed
|
||||
@ -40,7 +51,9 @@ install_package() {
|
||||
else
|
||||
# Package not installed
|
||||
echo -e "${NOTE} Installing $1 ..."
|
||||
if sudo apt-get install -y "$1" 2>&1 | tee -a "$LOG"; then
|
||||
sudo apt-get install -y "$1" >> "$LOG" 2>&1
|
||||
# Check if the package was installed successfully
|
||||
if dpkg -l | grep -q -w "$1"; then
|
||||
echo -e "\e[1A\e[K${OK} $1 was installed."
|
||||
else
|
||||
# Something is missing, exiting to review the log
|
||||
|
||||
@ -37,7 +37,9 @@ install_package() {
|
||||
else
|
||||
# Package not installed
|
||||
echo -e "${NOTE} Installing $1 ..."
|
||||
if sudo apt-get install -y "$1" 2>&1 | tee -a "$LOG"; then
|
||||
sudo apt-get install -y "$1" >> "$LOG" 2>&1
|
||||
# Check if the package was installed successfully
|
||||
if dpkg -l | grep -q -w "$1"; then
|
||||
echo -e "\e[1A\e[K${OK} $1 was installed."
|
||||
else
|
||||
# Something is missing, exiting to review the log
|
||||
|
||||
@ -39,7 +39,7 @@ install_and_log() {
|
||||
printf "${OK} $project_name installed successfully.\n"
|
||||
if [ "$project_name" == "supergfxctl" ]; then
|
||||
# Enable supergfxctl
|
||||
sudo systemctl enable supergfxd.service --now
|
||||
sudo systemctl enable --now supergfxd 2>&1 | tee -a "$LOG"
|
||||
fi
|
||||
else
|
||||
echo -e "${ERROR} Installation failed for $project_name."
|
||||
|
||||
@ -32,7 +32,7 @@ set -e
|
||||
|
||||
# Install SDDM and Tokyo-Night theme
|
||||
for PKG1 in "${login[@]}" ; do
|
||||
sudo apt install --no-install-recommends -y "$PKG1" 2>&1 | tee -a "$LOG"
|
||||
sudo apt-get install --no-install-recommends -y "$PKG1" 2>&1 | tee -a "$LOG"
|
||||
if [ $? -ne 0 ]; then
|
||||
echo -e "\e[1A\e[K${ERROR} - $PKG1 install had failed, please check the install.log"
|
||||
exit 1
|
||||
@ -41,7 +41,7 @@ done
|
||||
|
||||
# Check if other login managers are installed and disabling their service before enabling sddm
|
||||
for login_manager in lightdm gdm lxdm lxdm-gtk3; do
|
||||
if sudo apt list installed "$login_manager" &>> /dev/null; then
|
||||
if sudo apt-get list installed "$login_manager" &>> /dev/null; then
|
||||
echo "Disabling $login_manager..."
|
||||
sudo systemctl disable "$login_manager" 2>&1 | tee -a "$LOG"
|
||||
fi
|
||||
|
||||
@ -39,7 +39,9 @@ install_package() {
|
||||
else
|
||||
# Package not installed
|
||||
echo -e "${NOTE} Installing $1 ..."
|
||||
if sudo apt-get install -y "$1" 2>&1 | tee -a "$LOG"; then
|
||||
sudo apt-get install -y "$1" >> "$LOG" 2>&1
|
||||
# Check if the package was installed successfully
|
||||
if dpkg -l | grep -q -w "$1"; then
|
||||
echo -e "\e[1A\e[K${OK} $1 was installed."
|
||||
else
|
||||
# Something is missing, exiting to review the log
|
||||
|
||||
@ -48,17 +48,17 @@ printf "\n"
|
||||
# Clean out other portals
|
||||
printf "${NOTE} Clearing any other xdg-desktop-portal implementations...\n"
|
||||
# Check if packages are installed and uninstall if present
|
||||
if sudo apt list installed xdg-desktop-portal-gnome &>> /dev/null; then
|
||||
if sudo apt-get list installed xdg-desktop-portal-gnome &>> /dev/null; then
|
||||
echo "Removing xdg-desktop-portal-gnome..."
|
||||
sudo apt remove -y xdg-desktop-portal-gnome 2>&1 | tee -a "$LOG"
|
||||
sudo apt-get remove -y xdg-desktop-portal-gnome 2>&1 | tee -a "$LOG"
|
||||
fi
|
||||
if sudo apt list installed xdg-desktop-portal-wlr &>> /dev/null; then
|
||||
if sudo apt-get list installed xdg-desktop-portal-wlr &>> /dev/null; then
|
||||
echo "Removing xdg-desktop-portal-wlr..."
|
||||
sudo apt remove -y xdg-desktop-portal-wlr 2>&1 | tee -a "$LOG"
|
||||
sudo apt-get remove -y xdg-desktop-portal-wlr 2>&1 | tee -a "$LOG"
|
||||
fi
|
||||
if sudo apt list installed xdg-desktop-portal-lxqt &>> /dev/null; then
|
||||
if sudo apt-get list installed xdg-desktop-portal-lxqt &>> /dev/null; then
|
||||
echo "Removing xdg-desktop-portal-lxqt..."
|
||||
sudo apt remove -y xdg-desktop-portal-lxqt 2>&1 | tee -a "$LOG"
|
||||
sudo apt-get remove -y xdg-desktop-portal-lxqt 2>&1 | tee -a "$LOG"
|
||||
fi
|
||||
|
||||
sed -i '17s/#//' config/hypr/configs/Execs.conf
|
||||
|
||||
@ -32,7 +32,9 @@ install_package() {
|
||||
else
|
||||
# Package not installed
|
||||
echo -e "${NOTE} Installing $1 ..."
|
||||
if sudo apt-get install -y "$1" 2>&1 | tee -a "$LOG"; then
|
||||
sudo apt-get install -y "$1" >> "$LOG" 2>&1
|
||||
# Check if the package was installed successfully
|
||||
if dpkg -l | grep -q -w "$1"; then
|
||||
echo -e "\e[1A\e[K${OK} $1 was installed."
|
||||
else
|
||||
# Something is missing, exiting to review the log
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user