From 50188ed1caede68e760453503a6d587e1ff984d6 Mon Sep 17 00:00:00 2001 From: pvincent Date: Thu, 20 Aug 2026 12:33:29 +0400 Subject: [PATCH] ghostty etc link --- lib/initiate.bash | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) diff --git a/lib/initiate.bash b/lib/initiate.bash index 691e943..0c47474 100644 --- a/lib/initiate.bash +++ b/lib/initiate.bash @@ -149,24 +149,15 @@ function build_associative_user_homes { } function ghostty_global_config { - ! command -v ghostty >/dev/null && return - - # ghostty exists - [[ ! -d /etc/ghostty ]] && mkdir -p /etc/ghostty - local global_config=/etc/ghostty/config - local asset_config="$MIAOU_BASH_DIR"/assets/ghostty/config - if [[ ! -f "$global_config" ]]; then - cp "$asset_config" "$global_config" - echo 'ghostty global config created' - elif ! cmp -s "$asset_config" "$global_config"; then - cp "$asset_config" "$global_config" - echo 'ghostty global config replaced' - fi + ! command -v ghostty >/dev/null && return # ghostty not yet installed! + + sudo mkdir -p /etc/ghostty + link_etc config ghostty if [[ ! -f /etc/skell/.config/ghostty/config ]]; then # ghostty config skeleton for new users mkdir -p /etc/skel/.config/ghostty - echo "config-file = $global_config" >/etc/skel/.config/ghostty/config + echo 'config-file = /etc/ghostty/config' >/etc/skel/.config/ghostty/config fi # change ghostty configuration for any normal user