From b6e198ddf3e65976653e6f84296276be49b7b066 Mon Sep 17 00:00:00 2001 From: Guillem George Date: Tue, 25 Nov 2025 17:58:01 +0100 Subject: [PATCH] Installer update --- README.md | 20 ++++++++++++++++++++ install-pkgs.sh | 12 ------------ install.sh | 14 ++++++++++++++ scripts/afs-install.sh | 35 +++++++++++++++++++++++++++++++++++ scripts/boussole.sh | 29 +++++++++++++++++++++++++++++ 5 files changed, 98 insertions(+), 12 deletions(-) create mode 100644 README.md delete mode 100755 install-pkgs.sh create mode 100755 install.sh create mode 100755 scripts/afs-install.sh create mode 100755 scripts/boussole.sh diff --git a/README.md b/README.md new file mode 100644 index 0000000..6fd0f5a --- /dev/null +++ b/README.md @@ -0,0 +1,20 @@ +# Boussole Desktop + +## Installation + +**WARNING** installer considers that '~/afs/' exists + +'''sh +git clone https://forge.oblic-parallels.fr/guillm/boussole.git +cd boussole +./install.sh +''' + +## Uninstallation + +**WARNING** This will reset all your config files in your AFS + +'''sh +cd ~/afs +git restore . +''' diff --git a/install-pkgs.sh b/install-pkgs.sh deleted file mode 100755 index 2cdef15..0000000 --- a/install-pkgs.sh +++ /dev/null @@ -1,12 +0,0 @@ -# Essentials -nix profile install nixpkgs#helix -# Shell -nix profile install nixpkgs#zsh nixpkgs#fzf nixpkgs#zoxide nixpkgs#eza -# Desktop -nix profile install nixpkgs#hyprland nixpkgs#rofi-wayland nixpkgs#hyprlock nixpkgs#waybar nixpkgs#xwayland nixpkgs#foot nixpkgs#hyprpaper -nix profile install nixpkgs#swaynotificationcenter nixpkgs#nerd-fonts.jetbrains-mono nixpkgs#nerd-fonts.dejavu-sans-mono -nix profile install nixpkgs#grim nixpkgs#slurp nixpkgs#wl-clipboard - -echo "Start ?" -read -hyprland diff --git a/install.sh b/install.sh new file mode 100755 index 0000000..cef38a6 --- /dev/null +++ b/install.sh @@ -0,0 +1,14 @@ +# .confs +cp -r ./.config/* ~/afs/.confs/config +cp -r ./.local/* ~/afs/.confs/local +cp -r ./.p10k.zsh ~/afs/.confs/p10k.zsh +cp -r ./.zshrc ~/afs/.confs/zshrc +cp -r ./afs-install.sh ~/afs/.confs/install.sh + +# install.sh (launched at session startup) +cp -r ./scripts/afs-install.sh ~/afs/.confs/install.sh + +# boussole.sh (launched by the user) +cp -r ./scripts/boussole.sh ~/afs/boussole.sh + +echo Done diff --git a/scripts/afs-install.sh b/scripts/afs-install.sh new file mode 100755 index 0000000..2e4e6a3 --- /dev/null +++ b/scripts/afs-install.sh @@ -0,0 +1,35 @@ +#!/bin/sh + +rplc_ln="\e[1A\e[K" +echo + +# Dotfiles (default) +echo -e "${rplc_ln}Linking dotfiles" +mkdir -p "$HOME/.local/share" +mkdir -p "$HOME/.local/.cache" +dot_list="bashrc config emacs gitconfig gitignore jnewsrc mozilla msmtprc muttrc signature slrnrc ssh thunderbird vim vimrc Xdefaults clang-format bash_profile local/bin local/share/icons" +for f in $dot_list; do + rm -rf "$HOME/.$f" + ln -s "$AFS_DIR/.confs/$f" "$HOME/.$f" +done + + +# Instant dotfiles +# echo -e "${rplc_ln}Copying dotfiles" +# instant_list="zshrc p10k.zsh local/share/zinit local/share/rofi" +# mkdir -p "$HOME/.local/share" +# for f in $instant_list; do +# rm -rf "$HOME/.$f" +# cp -r "$AFS_DIR/.confs/$f" "$HOME/.$f" +# done + + +# Documents +echo -e "${rplc_ln}Linking documents" +doc_list="Pictures Workplan" +for f in $doc_list; do + rm -rf "$HOME/$f" + ln -s "$AFS_DIR/$f" "$HOME/$f" +done + +echo -e "Config: done !" diff --git a/scripts/boussole.sh b/scripts/boussole.sh new file mode 100755 index 0000000..5039ca4 --- /dev/null +++ b/scripts/boussole.sh @@ -0,0 +1,29 @@ +rplc_ln="\e[1A\e[K" +echo + +# Essentials +echo -e "${rplc_ln}Installing essentials" +nix profile install nixpkgs#helix +# Shell +echo -e "${rplc_ln}Installing cli utilities" +nix profile install nixpkgs#zsh nixpkgs#fzf nixpkgs#zoxide nixpkgs#eza +# Desktop +echo -e "${rplc_ln}Installing desktop" +nix profile install nixpkgs#hyprland nixpkgs#rofi-wayland nixpkgs#hyprlock nixpkgs#waybar nixpkgs#xwayland nixpkgs#foot nixpkgs#hyprpaper +echo -e "${rplc_ln}Installing desktop utilities" +nix profile install nixpkgs#swaynotificationcenter nixpkgs#nerd-fonts.jetbrains-mono nixpkgs#nerd-fonts.dejavu-sans-mono +nix profile install nixpkgs#grim nixpkgs#slurp nixpkgs#wl-clipboard + +# Instant dotfiles +echo -e "${rplc_ln}Copying dotfiles" +instant_list="zshrc p10k.zsh local/share/zinit local/share/rofi" +mkdir -p "$HOME/.local/share" +for f in $instant_list; do + rm -rf "$HOME/.$f" + cp -r "$AFS_DIR/.confs/$f" "$HOME/.$f" +done + + +echo e "${rplc_ln}Start ?" +read +hyprland