Compare commits

...

25 Commits

Author SHA1 Message Date
JaKooLit 54b65e92b8 added qalculate-gtk 2024-10-08 23:52:28 +09:00
JaKooLit 84a413c615 added tip for searchable keybinds via rofi 2024-09-21 22:27:11 +09:00
JaKooLit cea9183d2d User will be ask if they want to set Thunar as default file manager if they decided to install it 2024-09-20 20:05:50 +09:00
JaKooLit 8eef96db51 small tweak 2024-09-20 18:55:13 +09:00
JaKooLit f99474f81f updated thunar and preset.sh 2024-09-20 18:51:13 +09:00
JaKooLit 10a1e9142d updaed preset.sh 2024-09-20 18:40:02 +09:00
JaKooLit b4bfd935d9 updated zsh.sh 2024-09-20 17:43:10 +09:00
JaKooLit 17b836ee2f Added fastfetch on tty. However, will be disabled if user decided to install pokemon colorscripts 2024-09-19 17:05:05 +09:00
JaKooLit 54bc0d1499 updated install.sh 2024-09-18 23:35:44 +09:00
JaKooLit 0e876533c2 ask user if thunar wants to be default. some formatting changes 2024-09-18 17:13:17 +09:00
JaKooLit f096714637 dotfiles will now be downloaded from main or master branch instead of from the releases version. 2024-09-18 14:32:20 +09:00
JaKooLit 38f24a43bb added dotfiles-main.sh to download from main instead of from releases 2024-09-18 01:21:47 +09:00
JaKooLit 0ed0894c38 switched over to non-bin yay or paru 2024-09-16 01:48:54 +09:00
JaKooLit c0b198d562 Final tweaks of color variants for output messages 2024-09-14 17:08:00 +09:00
JaKooLit 99cc2c481b Some changes on numbers on install scripts 2024-09-14 13:12:01 +09:00
JaKooLit b16dffda4d another update for uninstallation process 2024-09-14 11:40:36 +09:00
JaKooLit 04995241c4 updated uninstall functions 2024-09-14 11:32:32 +09:00
JaKooLit 44b58b3c65 just a bit tweak of final check script 2024-09-14 01:55:29 +09:00
JaKooLit eb033d3220 final tweak of install scripts 2024-09-14 01:29:54 +09:00
JaKooLit ba7dcc8523 updated Final-Check.sh 2024-09-14 01:28:27 +09:00
JaKooLit bbc3094e3d update Install scripts 2024-09-14 01:16:32 +09:00
JaKooLit 8ad8784443 updated - added final check of install packages 2024-09-14 00:48:15 +09:00
JaKooLit 477545ac2e just color tweak 2024-09-08 14:55:13 +09:00
Ja.KooLit 5f59d96640
Merge pull request #147 from JaKooLit/development
Development to Main
2024-09-08 11:55:22 +09:00
Ja.KooLit fb2866eed1
Update install.sh 2024-09-08 11:08:51 +09:00
18 changed files with 202 additions and 91 deletions

View File

@ -1,5 +1,17 @@
## Changelogs
## 20 Sep 2024
- User will be ask if they want to set Thunar as default file manager if they decided to install it
## 19 Sep 2024
- Added fastfetch on tty. However, will be disabled if user decided to install pokemon colorscripts
## 18 Sep 2024
- dotfiles will now be downloaded from main or master branch instead of from the releases version.
## 14 Sep 2024
- remove the final error checks instead, introduced a final check of essential packages to ran Hyprland
## 08 Sep 2024
- Added final error checks on install-logs

View File

@ -144,6 +144,8 @@ source ~/.zshrc
#### ⌨ Keybinds
- Keybinds [`CLICK`](https://github.com/JaKooLit/Hyprland-Dots/wiki/Keybinds)
> [!TIP]
> KooL's Dots v2.3.7 has a searchable keybind function via rofi. (SUPER SHIFT K) or right click the `HINTS` waybar button
#### 🙋 👋 Having issues or questions?
- for the install part, kindly open issue on this repo

View File

@ -21,6 +21,9 @@ source $ZSH/oh-my-zsh.sh
# Project page: https://gitlab.com/phoneybadger/pokemon-colorscripts#on-other-distros-and-macos
#pokemon-colorscripts --no-title -s -r
# fastfetch. Will be disabled if above colorscript was chosen to install
fastfetch -c $HOME/.config/fastfetch/config-compact.jsonc
# Set-up icons for files/folders in terminal
alias ls='eza -a --icons'
alias ll='eza -al --icons'

View File

@ -1,5 +0,0 @@
[Desktop Entry]
Name=Hyprland
Comment=An intelligent dynamic tiling Wayland compositor
Exec=Hyprland
Type=Application

View File

@ -64,6 +64,7 @@ hypr_package_2=(
nvtop
nwg-look
pacman-contrib
qalculate-gtk
vim
yt-dlp
)
@ -90,15 +91,23 @@ source "$(dirname "$(readlink -f "$0")")/Global_functions.sh"
LOG="Install-Logs/install-$(date +%d-%H%M%S)_hypr-pkgs.log"
# uninstalling conflicting packages
printf "\n%s - Removing Mako, Dunst and rofi as it conflicts with swaync and rofi-wayland \n" "${NOTE}"
# Initialize a variable to track overall errors
overall_failed=0
printf "\n%s - Removing Mako, Dunst, and rofi as they conflict with swaync and rofi-wayland \n" "${NOTE}"
for PKG in "${uninstall[@]}"; do
uninstall_package "$PKG" 2>&1 | tee -a "$LOG"
if [ $? -ne 0 ]; then
echo -e "\e[1A\e[K${ERROR} - $PKG uninstallation failed, please check the log"
exit 1
# Track if any uninstallation failed
overall_failed=1
fi
done
if [ $overall_failed -ne 0 ]; then
echo -e "${ERROR} Some packages failed to uninstall. Please check the log."
fi
# Installation of main components
printf "\n%s - Installing hyprland packages.... \n" "${NOTE}"

View File

@ -0,0 +1,67 @@
#!/bin/bash
# 💫 https://github.com/JaKooLit 💫 #
# Final checking if packages are installed
# NOTE: These package check are only the essentials
packages=(
aylurs-gtk-shell
cliphist
kvantum
rofi-wayland
imagemagick
swaync
swww
wallust
waybar
wl-clipboard
wlogout
kitty
hypridle
hyprlock
hyprland
pyprland
)
## WARNING: DO NOT EDIT BEYOND THIS LINE IF YOU DON'T KNOW WHAT YOU ARE DOING! ##
# Determine the directory where the script is located
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
# Change the working directory to the parent directory of the script
PARENT_DIR="$SCRIPT_DIR/.."
cd "$PARENT_DIR" || exit 1
source "$(dirname "$(readlink -f "$0")")/Global_functions.sh"
# Set the name of the log file to include the current date and time
LOG="Install-Logs/00_CHECK-$(date +%d-%H%M%S)_installed.log"
printf "\n%s - Final Check if essential packages where installed \n" "${NOTE}"
# Initialize an empty array to hold missing packages
missing=()
# Loop through each package
for pkg in "${packages[@]}"; do
# Check if the package is installed
if ! pacman -Qi "$pkg" > /dev/null 2>&1; then
missing+=("$pkg")
fi
done
# Check if the missing array is empty or not
if [ ${#missing[@]} -eq 0 ]; then
echo "${OK} All essential packages are installed." | tee -a "$LOG"
else
# Message to user on missing packages
echo "${WARN} The following packages are missing and will be logged:"
# Log only the missing packages and inform the user
for pkg in "${missing[@]}"; do
echo "$pkg"
echo "$pkg" >> "$LOG" # Log the missing package to the file
done
# Add a timestamp when the missing packages were logged
echo "${NOTE} Missing packages logged at $(date)" >> "$LOG"
fi

View File

@ -8,7 +8,7 @@ set -e
OK="$(tput setaf 2)[OK]$(tput sgr0)"
ERROR="$(tput setaf 1)[ERROR]$(tput sgr0)"
NOTE="$(tput setaf 3)[NOTE]$(tput sgr0)"
WARN="$(tput setaf 166)[WARN]$(tput sgr0)"
WARN="$(tput setaf 5)[WARN]$(tput sgr0)"
CAT="$(tput setaf 6)[ACTION]$(tput sgr0)"
ORANGE=$(tput setaf 166)
YELLOW=$(tput setaf 3)
@ -65,18 +65,22 @@ install_package() {
# Function for uninstalling packages
uninstall_package() {
local pkg="$1"
# Checking if package is installed
if pacman -Qi "$1" &>> /dev/null ; then
if pacman -Qi "$pkg" &>> /dev/null ; then
# Package is installed
echo -e "${NOTE} Uninstalling $1 ..."
sudo pacman -R --noconfirm "$1" 2>&1 | tee -a "$LOG"
# Making sure package is uninstalled
if ! pacman -Qi "$1" &>> /dev/null ; then
echo -e "\e[1A\e[K${OK} $1 was uninstalled."
echo -e "${NOTE} Uninstalling $pkg ..."
sudo pacman -R --noconfirm "$pkg" 2>&1 | tee -a "$LOG" | grep -v "error: target not found"
# Check if the package was uninstalled
if ! pacman -Qi "$pkg" &>> /dev/null ; then
echo -e "\e[1A\e[K${OK} $pkg was uninstalled."
else
# Something went wrong, exiting to review log
echo -e "\e[1A\e[K${ERROR} $1 failed to uninstall. Please check the log."
exit 1
echo -e "\e[1A\e[K${ERROR} $pkg failed to uninstall. Please check the log."
return 1
fi
else
echo -e "${NOTE} $pkg is not installed, skipping uninstallation."
fi
}
return 0
}

View File

@ -22,7 +22,9 @@ LOG="Install-Logs/install-$(date +%d-%H%M%S)_input.log"
while true; do
echo "${WARN} This script will add your user to the 'input' group."
echo "${NOTE} Please note that adding yourself to the 'input' group might be necessary for waybar keyboard-state functionality."
printf "\n%.0s" {1..1}
if [[ -z $input_group_choid ]]; then
read -p "${YELLOW}Do you want to proceed? (y/n): ${RESET}" input_group_choid
fi

View File

@ -0,0 +1,29 @@
#!/bin/bash
# 💫 https://github.com/JaKooLit 💫 #
# Hyprland-Dots to download from main #
## WARNING: DO NOT EDIT BEYOND THIS LINE IF YOU DON'T KNOW WHAT YOU ARE DOING! ##
source "$(dirname "$(readlink -f "$0")")/Global_functions.sh"
# Check if Hyprland-Dots exists
printf "${NOTE} Downloading KooL's Hyprland Dots....\n"
if [ -d Hyprland-Dots ]; then
cd Hyprland-Dots
git stash
git pull
git stash apply
chmod +x copy.sh
./copy.sh
else
if git clone --depth 1 https://github.com/JaKooLit/Hyprland-Dots; then
cd Hyprland-Dots || exit 1
chmod +x copy.sh
./copy.sh
else
echo -e "$ERROR Can't download Hyprland-Dots"
fi
fi
clear

View File

@ -12,7 +12,7 @@ LOG="install-$(date +%d-%H%M%S)_paru.log"
OK="$(tput setaf 2)[OK]$(tput sgr0)"
ERROR="$(tput setaf 1)[ERROR]$(tput sgr0)"
NOTE="$(tput setaf 3)[NOTE]$(tput sgr0)"
WARN="$(tput setaf 166)[WARN]$(tput sgr0)"
WARN="$(tput setaf 5)[WARN]$(tput sgr0)"
CAT="$(tput setaf 6)[ACTION]$(tput sgr0)"
ORANGE=$(tput setaf 166)
YELLOW=$(tput setaf 3)
@ -24,9 +24,9 @@ if [ ! -d Install-Logs ]; then
mkdir Install-Logs
fi
# checking if paru-bin exist and removing if it is
if [ -d paru-bin ]; then
rm -rf paru-bin 2>&1 | tee -a "$LOG"
# checking if paru exist and removing if it is
if [ -d paru ]; then
rm -rf paru 2>&1 | tee -a "$LOG"
fi
# Check for AUR helper and install if not found
@ -37,8 +37,8 @@ if [ -n "$ISAUR" ]; then
else
printf "\n%s - AUR helper was NOT located\n" "$WARN"
printf "\n%s - Installing paru from AUR\n" "${NOTE}"
git clone https://aur.archlinux.org/paru-bin.git || { printf "%s - Failed to clone paru from AUR\n" "${ERROR}"; exit 1; }
cd paru-bin || { printf "%s - Failed to enter paru-bin directory\n" "${ERROR}"; exit 1; }
git clone https://aur.archlinux.org/paru.git || { printf "%s - Failed to clone paru from AUR\n" "${ERROR}"; exit 1; }
cd paru || { printf "%s - Failed to enter paru directory\n" "${ERROR}"; exit 1; }
makepkg -si --noconfirm 2>&1 | tee -a "$LOG" || { printf "%s - Failed to install paru from AUR\n" "${ERROR}"; exit 1; }
# moving install logs in to Install-Logs folder

View File

@ -27,12 +27,6 @@ LOG="Install-Logs/install-$(date +%d-%H%M%S)_pipewire.log"
ISAUR=$(command -v yay || command -v paru)
# Removal of pulseaudio
printf "${YELLOW}Removing pulseaudio stuff...${RESET}\n"
for pulseaudio in pulseaudio pulseaudio-alsa pulseaudio-bluetooth; do
sudo pacman -R --noconfirm "$pulseaudio" 2>/dev/null | tee -a "$LOG" || true
done
# Disabling pulseaudio to avoid conflicts
systemctl --user disable --now pulseaudio.socket pulseaudio.service 2>/dev/null && tee -a "$LOG"

View File

@ -52,7 +52,8 @@ sddm_conf_dir=/etc/sddm.conf.d
wayland_sessions_dir=/usr/share/wayland-sessions
[ ! -d "$wayland_sessions_dir" ] && { printf "$CAT - $wayland_sessions_dir not found, creating...\n"; sudo mkdir "$wayland_sessions_dir" 2>&1 | tee -a "$LOG"; }
sudo cp assets/hyprland.desktop "$wayland_sessions_dir/" 2>&1 | tee -a "$LOG"
printf "\n%.0s" {1..2}
# SDDM-themes
valid_input=false

View File

@ -2,6 +2,10 @@
# 💫 https://github.com/JaKooLit 💫 #
# Thunar #
if [[ $USE_PRESET = [Yy] ]]; then
source ./preset.sh
fi
thunar=(
thunar
thunar-volman
@ -32,6 +36,22 @@ printf "${NOTE} Installing Thunar Packages...\n"
[ $? -ne 0 ] && { echo -e "\e[1A\e[K${ERROR} - $THUNAR Package installation failed, Please check the installation logs"; exit 1; }
done
printf "\n%.0s" {1..2}
# Ask the user if they want to use Thunar as the default file manager
read -p "${CAT} Do you want to set Thunar as the default file manager? (y/n): " thunar_default
if [[ "$thunar_default" == [Yy] ]]; then
# Setting Thunar as the default file manager
xdg-mime default thunar.desktop inode/directory
xdg-mime default thunar.desktop application/x-wayland-gnome-saved-search
echo "${OK} Thunar has been set as the default file manager." 2>&1 | tee -a "$LOG"
else
echo "${NOTE} you choose not to set Thunar as default file manager." 2>&1 | tee -a "$LOG"
fi
printf "\n"
# Check for existing configs and copy if does not exist
for DIR1 in gtk-3.0 Thunar xfce4; do
DIRPATH=~/.config/$DIR1

View File

@ -32,14 +32,13 @@ for xdgs in "${xdg[@]}"; do
exit 1
fi
done
printf "\n"
printf "${NOTE} Checking for other XDG-Desktop-Portal-Implementations....\n"
sleep 1
printf "\n"
printf "${NOTE} XDG-desktop-portal-KDE & GNOME (if installed) should be manually disabled or removed! I can't remove it... sorry...\n"
while true; do
printf "\n%.0s" {1..2}
if [[ -z $XDPH1 ]]; then
read -rp "${CAT} Would you like to try to remove other XDG-Desktop-Portal-Implementations? (y/n) " XDPH1
fi

View File

@ -12,7 +12,7 @@ LOG="install-$(date +%d-%H%M%S)_yay.log"
OK="$(tput setaf 2)[OK]$(tput sgr0)"
ERROR="$(tput setaf 1)[ERROR]$(tput sgr0)"
NOTE="$(tput setaf 3)[NOTE]$(tput sgr0)"
WARN="$(tput setaf 166)[WARN]$(tput sgr0)"
WARN="$(tput setaf 5)[WARN]$(tput sgr0)"
CAT="$(tput setaf 6)[ACTION]$(tput sgr0)"
ORANGE=$(tput setaf 166)
YELLOW=$(tput setaf 3)
@ -23,9 +23,9 @@ if [ ! -d Install-Logs ]; then
mkdir Install-Logs
fi
# Check Existing yay-bin
if [ -d yay-bin ]; then
rm -rf yay-bin 2>&1 | tee -a "$LOG"
# Check Existing yay
if [ -d yay ]; then
rm -rf yay 2>&1 | tee -a "$LOG"
fi
# Check for AUR helper and install if not found
@ -35,8 +35,8 @@ if [ -n "$ISAUR" ]; then
else
printf "\n%s - AUR helper was NOT located\n" "$WARN"
printf "\n%s - Installing yay from AUR\n" "${NOTE}"
git clone https://aur.archlinux.org/yay-bin.git || { printf "%s - Failed to clone yay from AUR\n" "${ERROR}"; exit 1; }
cd yay-bin || { printf "%s - Failed to enter yay-bin directory\n" "${ERROR}"; exit 1; }
git clone https://aur.archlinux.org/yay.git || { printf "%s - Failed to clone yay from AUR\n" "${ERROR}"; exit 1; }
cd yay || { printf "%s - Failed to enter yay directory\n" "${ERROR}"; exit 1; }
makepkg -si --noconfirm 2>&1 | tee -a "$LOG" || { printf "%s - Failed to install yay from AUR\n" "${ERROR}"; exit 1; }
# moving install logs in to Install-Logs folder

View File

@ -34,7 +34,11 @@ while true; do
case "$pokemon_choice" in
[Yy]*)
zsh+=('pokemon-colorscripts-git')
sed -i '/#pokemon-colorscripts --no-title -s -r/s/^#//' assets/.zshrc
sed -i '/#pokemon-colorscripts --no-title -s -r/s/^#//' assets/.zshrc >> "$LOG" 2>&1
# commenting out fastfetch since pokemon was chosen to install
sed -i '/^fastfetch -c $HOME\/.config\/fastfetch\/config-compact.jsonc/s/^/#/' assets/.zshrc >> "$LOG" 2>&1
break
;;
[Nn]*)

View File

@ -5,7 +5,7 @@
OK="$(tput setaf 2)[OK]$(tput sgr0)"
ERROR="$(tput setaf 1)[ERROR]$(tput sgr0)"
NOTE="$(tput setaf 3)[NOTE]$(tput sgr0)"
WARN="$(tput setaf 166)[WARN]$(tput sgr0)"
WARN="$(tput setaf 5)[WARN]$(tput sgr0)"
CAT="$(tput setaf 6)[ACTION]$(tput sgr0)"
ORANGE=$(tput setaf 166)
YELLOW=$(tput setaf 3)
@ -21,7 +21,7 @@ fi
clear
# Check if PulseAudio package is installed
if pacman -Qq | grep -qw pulseaudio; then
if pacman -Qq | grep -qw '^pulseaudio$'; then
echo "$ERROR PulseAudio is detected as installed. Uninstall it first or edit install.sh on line 211 (execute_script 'pipewire.sh')."
exit 1
fi
@ -209,7 +209,7 @@ elif [ "$aur_helper" == "yay" ]; then
fi
# Install hyprland packages
execute_script "00-hypr-pkgs.sh"
execute_script "01-hypr-pkgs.sh"
# Install pipewire and pipewire-audio
execute_script "pipewire.sh"
@ -255,69 +255,38 @@ if [ "$rog" == "Y" ]; then
fi
if [ "$dots" == "Y" ]; then
execute_script "dotfiles.sh"
execute_script "dotfiles-main.sh"
fi
clear
printf "\n%.0s" {1..3}
# Error-checking section
LOG_DIR="Install-Logs"
ERROR_FILE="$LOG_DIR/00-Error.log"
# Create or clear the error file
: > "$ERROR_FILE"
# Check if the Install-Logs directory exists
if [ -d "$LOG_DIR" ]; then
# Iterate through each file in the Install-Logs directory
for log_file in "$LOG_DIR"/*; do
# Check if it's a file
if [ -f "$log_file" ]; then
# Search for lines containing the word "error" (case-insensitive) in the log file
if grep -i "error" "$log_file" > /dev/null; then
# If errors are found, add the filename to the error file
echo "${WARN} Errors found in file: $(basename "$log_file")" >> "$ERROR_FILE"
fi
fi
done
# Check if the error file has any content
if [ -s "$ERROR_FILE" ]; then
echo "${ERROR} Errors encountered during Installation. See $ERROR_FILE for details."
else
echo "${OK} No errors were found."
fi
else
echo "Directory $LOG_DIR does not exist or could not be found."
fi
# final check essential packages if it is installed
execute_script "02-Final-Check.sh"
printf "\n%.0s" {1..1}
# Check if hyprland or hyprland-git is installed
if pacman -Q hyprland &> /dev/null || pacman -Q hyprland-git &> /dev/null; then
printf "\n${OK} Hyprland is installed. However, there may some errors during installation "
printf "\n${CAT} Please see the errors in Install-Logs as stated above\n"
sleep 2
printf "\n${NOTE} You can start Hyprland by typing Hyprland (IF SDDM is not installed) (note the capital H!).\n"
printf "\n"
printf "\n${NOTE} However, It is highly recommended to reboot your system.\n\n"
printf "\n${OK} Hyprland is installed. However, some essential packages may not be installed Please see above!"
printf "\n${CAT} Ignore this message if it states 'All essential packages are installed.'\n"
sleep 2
printf "\n${NOTE} You can start Hyprland by typing 'Hyprland' (IF SDDM is not installed) (note the capital H!).\n"
printf "\n${NOTE} However, it is highly recommended to reboot your system.\n\n"
# Prompt user to reboot
read -rp "${CAT} Would you like to reboot now? (y/n): " HYP
# Check if the user answered 'y' or 'Y'
if [[ "$HYP" =~ ^[Yy]$ ]]; then
if [[ "$nvidia" == "Y" ]]; then
echo "${NOTE} NVIDIA GPU detected. Rebooting the system..."
systemctl reboot
else
systemctl reboot
fi
fi
systemctl reboot
fi
else
# Print error message if neither package is installed
printf "\n${WARN} Hyprland failed to install. Please check Error Log and Install-Logs directory...\n\n"
printf "\n${WARN} Hyprland failed to install. Please check 00_CHECK-time_installed.log and other files Install-Logs/ directory...\n\n"
exit 1
fi

View File

@ -32,11 +32,12 @@ dots="Y"
### These are the sub-questions of the above choices
### Would you like to blacklist nouveau? (y/n)
blacklist_nouveau="Y"
# Ask the user if they want to use Thunar as the default file manager
# Do you want to set Thunar as the default file manager? (y/n): "
thunar_default="Y"
### XDG-desktop-portal-KDE & GNOME (if installed) should be manually disabled or removed! Script cant remove nor disable it.
### Would you like to try to remove other XDG-Desktop-Portal-Implementations? (y/n)
XDPH1="Y"
### SDDM is already installed. Would you like to manually install sddm-git to remove it? This requires manual intervention. (y/n)
manual_install_sddm="N"
### OPTIONAL - Would you like to install SDDM themes? (y/n)
install_sddm_theme="Y"
### " This script will add your user to the 'input' group."