Ajout Menu Principal

This commit is contained in:
lebartal committed 2026-01-24 14:30:23 +01:00
1 parent 06cadc6535
commit 16d11ca7e0
5 files changed
+77 -26

No files matched your search

+145
View File
@@ -0,0 +1,145 @@
#!/bin/bash
set -eou pipefail
# Couleurs de texte (Foreground)
NOIR='\e[30m'
ROUGE='\e[31m'
VERT='\e[32m'
JAUNE='\e[33m'
BLEU='\e[34m'
VIOLET='\e[35m'
CYAN='\e[36m'
BLANC='\e[37m'
# Couleurs de fond (Background)
BG_NOIR='\e[40m'
BG_ROUGE='\e[41m'
BG_VERT='\e[42m'
BG_JAUNE='\e[43m'
# Styles
GRAS='\e[1m'
SOULIGNE='\e[4m'
RESET="\e[0m"
# -------------- FONCTIONS ---------------
function maj_depot
{
#Actualisation depots
apt update
# Maj Systeme avant AutoInstall
apt full-upgrade -y
}
function maj_systeme
{
nala full-upgrade -y
}
function maj_packages
{
nala upgrade -y
}
function install_nala
{
#Installation NALA
curl https://gitlab.com/volian/volian-archive/-/raw/main/install-nala.sh | bash
}
function install_nerdfont
{
#Telechargement Nerdfonts (Police Hackfont, la plus lisible)
mkdir -p ~/.local/share/fonts/
#Installation de la Police
http -o ~/.local/share/fonts/Hack.zip --download https://github.com/ryanoasis/nerd-fonts/releases/download/v3.4.0/Hack.zip
unzip ~/.local/share/fonts/Hack.zip
rm ~/.local/share/fonts/Hack.zip
#Mise a jour des polices
fc-cache -f
}
function install_packages
{
add-apt-repository ppa:zhangsongcui3371/fastfetch -y
nala install btop httpie fastfetch
snap install lsd
}
function install_flatpaks
{
# 12/01/2026 desactivation des flatpak, ces derniers sont installables directement dans les depots de bases.
#Installation Flatpak
#add-apt-repository ppa:flatpak/stable -y
nala install flatpak -y
nala install gnome-software-plugin-flatpak -y
#flatpak remote-add --if-not-exists flathub https://dl.flathub.org/repo/flathub.flatpakrepo
#Installation Packages Flatpak
# <a faire plus tard>
}
function install_mainline
{
#Installation Mainline
add-apt-repository ppa:cappelikan/ppa -y
nala install mainline -y
}
function install_atuin
{
#Installation Atuin
bash <(curl https://raw.githubusercontent.com/atuinsh/atuin/main/install.sh)
}
function install_zsh
# ainsi que les plugins
{
nala install zsh -y
#Configuration zsh+plugins
sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
#Installation Plugin ZSH
git clone https://github.com/zsh-users/zsh-autosuggestions ~/.zsh/zsh-autosuggestions
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ~/.zsh/zsh-syntax-highlighting
git clone --depth=1 https://github.com/romkatv/powerlevel10k.git ~/.zsh/powerlevel10k
echo "source ~/.zsh/zsh-autosuggestions/zsh-autosuggestions.zsh" >> ~/.zshrc
echo "source ~/.zsh/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh" >> ~/.zshrc
echo "source ~/.zsh/powerlevel10k/powerlevel10k.zsh-theme" >> ~/.zshrc
# pré-chargement fichier zsh configure
#source ~/.zshrc
}
function config_alias
{
#Configuration megacommande maj"
echo "alias maj='nala full-upgrade && flatpak upgrade && mainline install-latest && update-grub'" >> ~/.zshrc
#Configuration des alias des commandes
# commande ll pour lister les fichier
echo "alias ll='lsd -ltr'" >> ~/.zshrc
# commande dl pour download
echo "alias dl ='http --download'" >> ~/.zshrc
# commande disque pour espace disque
echo "alias disque='duf' " >> ~/.zshrc
}
function config_zsh
{
#Relancer la config de zsh
p10k configure
}