Update v2/fedora-full.sh
fixed if SilentSDDM-theme was already cloned
This commit is contained in:
+15
-12
@@ -54,21 +54,24 @@ install_packages arandr catfish galculator NetworkManager network-manager-applet
|
|||||||
say_yellow "Installing SDDM Theme"
|
say_yellow "Installing SDDM Theme"
|
||||||
|
|
||||||
GIT_DIR="$HOME/git"
|
GIT_DIR="$HOME/git"
|
||||||
|
REPO_DIR="$GIT_DIR/SilentSDDM"
|
||||||
|
REPO_URL="https://github.com/uiriansan/SilentSDDM"
|
||||||
|
|
||||||
mkdir -p "$GIT_DIR"
|
mkdir -p "$GIT_DIR"
|
||||||
|
|
||||||
# Run the installation in a subshell to avoid changing the main script's working directory
|
if [ -d "$REPO_DIR/.git" ]; then
|
||||||
(
|
echo "SilentSDDM already exists. Updating repository..."
|
||||||
if cd "$GIT_DIR"; then
|
cd "$REPO_DIR" && git pull --rebase
|
||||||
echo "Successfully entered $GIT_DIR. Proceeding with SilentSDDM installation..."
|
else
|
||||||
|
echo "Cloning SilentSDDM..."
|
||||||
|
git clone -b main --depth=1 "$REPO_URL" "$REPO_DIR"
|
||||||
|
fi
|
||||||
|
|
||||||
git clone -b main --depth=1 https://github.com/uiriansan/SilentSDDM && \
|
echo "Running installer..."
|
||||||
cd SilentSDDM && \
|
cd "$REPO_DIR" || {
|
||||||
./install.sh
|
echo "Error: Failed to enter $REPO_DIR" >&2
|
||||||
else
|
exit 1
|
||||||
echo "Error: Failed to navigate to $GIT_DIR" >&2
|
}
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
)
|
|
||||||
|
|
||||||
# Ensure NetworkManager manages all interfaces
|
# Ensure NetworkManager manages all interfaces
|
||||||
say_yellow "Ensuring NetworkManager service is enabled and running..."
|
say_yellow "Ensuring NetworkManager service is enabled and running..."
|
||||||
|
|||||||
Reference in New Issue
Block a user