change
This commit is contained in:
@@ -3,6 +3,9 @@ set -euo pipefail
|
|||||||
|
|
||||||
LOG_FILE="$HOME/cachyos-post-install.log"
|
LOG_FILE="$HOME/cachyos-post-install.log"
|
||||||
|
|
||||||
|
GIT_USER_NAME="Jose Lago"
|
||||||
|
GIT_USER_EMAIL="jose@lago.dev"
|
||||||
|
|
||||||
OFFICIAL_PACKAGES=(
|
OFFICIAL_PACKAGES=(
|
||||||
brave-browser
|
brave-browser
|
||||||
chromium
|
chromium
|
||||||
@@ -831,6 +834,33 @@ ZSHFASTFETCH
|
|||||||
log "Fastfetch config written to: $fastfetch_config"
|
log "Fastfetch config written to: $fastfetch_config"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
configure_git_identity() {
|
||||||
|
log "Configuring global Git identity..."
|
||||||
|
|
||||||
|
if ! command -v git >/dev/null 2>&1; then
|
||||||
|
warn "git is not available. Skipping Git identity configuration."
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
|
||||||
|
current_git_name="$(git config --global --get user.name || true)"
|
||||||
|
current_git_email="$(git config --global --get user.email || true)"
|
||||||
|
|
||||||
|
if [[ "$current_git_name" == "$GIT_USER_NAME" ]]; then
|
||||||
|
log "Git user.name already set to: $GIT_USER_NAME"
|
||||||
|
else
|
||||||
|
git config --global user.name "$GIT_USER_NAME"
|
||||||
|
log "Git user.name set to: $GIT_USER_NAME"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "$current_git_email" == "$GIT_USER_EMAIL" ]]; then
|
||||||
|
log "Git user.email already set to: $GIT_USER_EMAIL"
|
||||||
|
else
|
||||||
|
git config --global user.email "$GIT_USER_EMAIL"
|
||||||
|
log "Git user.email set to: $GIT_USER_EMAIL"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
post_checks() {
|
post_checks() {
|
||||||
log "Quick checks..."
|
log "Quick checks..."
|
||||||
|
|
||||||
@@ -864,6 +894,7 @@ main() {
|
|||||||
full_system_update
|
full_system_update
|
||||||
install_drivers_with_chwd
|
install_drivers_with_chwd
|
||||||
install_official_packages
|
install_official_packages
|
||||||
|
configure_git_identity
|
||||||
remove_ptyxis_and_konsole_install_ghostty
|
remove_ptyxis_and_konsole_install_ghostty
|
||||||
configure_ghostty
|
configure_ghostty
|
||||||
configure_zsh_ohmyzsh_powerlevel10k
|
configure_zsh_ohmyzsh_powerlevel10k
|
||||||
|
|||||||
Reference in New Issue
Block a user