Compare commits
5
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7e4e7d29d5 | ||
|
|
c6f5512e44 | ||
|
|
16d11ca7e0 | ||
|
|
06cadc6535 | ||
|
|
840a7c3e6b |
No files matched your search
@@ -1,88 +0,0 @@
|
||||
#! /bin/bash
|
||||
#--------------------------------------------
|
||||
# Script autoinstallation et configuration Ubuntu
|
||||
#--------------------------------------------
|
||||
#Actualisation depots
|
||||
apt update
|
||||
|
||||
# Maj Systeme avant AutoInstall
|
||||
apt update && apt full-upgrade -y
|
||||
|
||||
#Installation NALA
|
||||
curl https://gitlab.com/volian/volian-archive/-/raw/main/install-nala.sh | bash
|
||||
|
||||
# MAJ Systeme
|
||||
nala full-upgrade -y
|
||||
|
||||
#Installation Packages
|
||||
apt install btop httpie lsd -y
|
||||
|
||||
#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
|
||||
|
||||
|
||||
# 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 Fastfetch
|
||||
add-apt-repository ppa:zhangsongcui3371/fastfetch -y
|
||||
nala install fastfetch -y
|
||||
|
||||
|
||||
#Installation Packages Flatpak
|
||||
# <a faire plus tard>
|
||||
|
||||
#Installation Mainline
|
||||
add-apt-repository ppa:cappelikan/ppa -y
|
||||
nala install mainline -y
|
||||
|
||||
#Installation Atuin
|
||||
bash <(curl https://raw.githubusercontent.com/atuinsh/atuin/main/install.sh)
|
||||
|
||||
#Installation ZSH
|
||||
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
|
||||
|
||||
#Configuration megacommande maj"
|
||||
echo "alias maj='nala full-upgrade && flatpak upgrade && mainline install-latest && update-grub'" >> ~/.zshrc
|
||||
|
||||
#Configuration des alias des commandes
|
||||
echo "alias ll='lsd -ltr'" >> ~/.zshrc
|
||||
echo "alias wget='http --download'" >> ~/.zshrc
|
||||
echo "alias du='duf' " >> ~/.zshrc
|
||||
|
||||
#Relancer la config de zsh
|
||||
#p10k configure
|
||||
|
||||
#Reboot
|
||||
# Ajouter un reboot a la fin
|
||||
echo ""
|
||||
echo ""
|
||||
echo "Installation Terminee"
|
||||
@@ -0,0 +1,52 @@
|
||||
#! /bin/bash
|
||||
set -eo pipefail
|
||||
|
||||
function check_source
|
||||
{
|
||||
source=$1
|
||||
if [[ -f "./sources/${source}" ]]; then
|
||||
{
|
||||
. ./sources/${source}
|
||||
}
|
||||
else
|
||||
{
|
||||
echo "Erreur : Impossible de charger les sources ${source}"
|
||||
exit 1
|
||||
}
|
||||
fi
|
||||
}
|
||||
|
||||
check_source "couleurs.ksh"
|
||||
|
||||
|
||||
#Affichage du Menu
|
||||
clear
|
||||
echo -e "${SOULIGNE}===== MENU GESTION LINUX =====${RESET} \n"
|
||||
echo -e "Votre Systeme : ${BG_NOIR}${BLEU}${systeme}${RESET}"
|
||||
echo ""
|
||||
echo "Quel module lancer ? "
|
||||
echo " [1] - AutoInstall"
|
||||
echo " [2] - MAJ"
|
||||
echo " [0] - Quitter"
|
||||
read reponse
|
||||
|
||||
case ${reponse} in
|
||||
|
||||
1)
|
||||
. ./modules/AutoInstall/autoinstall.ksh
|
||||
;;
|
||||
|
||||
2)
|
||||
. ./modules/AutoMaj/MAJ.ksh
|
||||
;;
|
||||
|
||||
0)
|
||||
exit
|
||||
;;
|
||||
|
||||
#Autre
|
||||
*)
|
||||
echo -e "${ROUGE}merci de repondre${RESET}"
|
||||
read reponse
|
||||
;;
|
||||
esac
|
||||
Executable
+74
@@ -0,0 +1,74 @@
|
||||
#! /bin/bash
|
||||
set -eo pipefail
|
||||
|
||||
#--------------------------------------------
|
||||
# Script autoinstallation et configuration Ubuntu/Debian
|
||||
#--------------------------------------------
|
||||
|
||||
function verif_source
|
||||
{
|
||||
source=$1
|
||||
if [[ -f "./modules/AutoInstall/sources/${source}" ]]; then
|
||||
{
|
||||
. ./modules/AutoInstall/sources/${source}
|
||||
}
|
||||
else
|
||||
{
|
||||
echo "Erreur : Impossible de charger les sources ${source}"
|
||||
exit 1
|
||||
}
|
||||
fi
|
||||
}
|
||||
|
||||
verif_source "fonctions.ksh"
|
||||
verif_source "couleurs.ksh"
|
||||
|
||||
# Recuperation de la distribution
|
||||
|
||||
if command -v lsb_release >/dev/null 2>&1; then
|
||||
systeme=$(lsb_release -d | cut -c 14-)
|
||||
else
|
||||
systeme="Inconnu (lsb_release non trouvé)"
|
||||
fi
|
||||
|
||||
|
||||
#Affichage du Menu
|
||||
clear
|
||||
echo -e "${SOULIGNE}===== AUTOINSTALL =====${RESET} \n"
|
||||
echo -e "Votre Systeme : ${BG_NOIR}${BLEU}${systeme}${RESET}"
|
||||
echo ""
|
||||
echo "Que voulez vous faire ? "
|
||||
echo "[1] - Installation complete"
|
||||
echo "[2] - Installer Nala"
|
||||
echo "[8] - Installer Atuin"
|
||||
echo "[9] - Installer Zsh+Plugins"
|
||||
echo "[0] - Quitter"
|
||||
read reponse
|
||||
|
||||
case ${reponse} in
|
||||
|
||||
1)
|
||||
maj_depot
|
||||
;;
|
||||
|
||||
2)
|
||||
install_nala
|
||||
;;
|
||||
|
||||
9)
|
||||
install_nerdfont
|
||||
install_zsh
|
||||
config_zsh
|
||||
;;
|
||||
|
||||
0)
|
||||
exit
|
||||
;;
|
||||
|
||||
#Autre
|
||||
*)
|
||||
echo -e "${ROUGE}merci de repondre${RESET}"
|
||||
read reponse
|
||||
;;
|
||||
esac
|
||||
|
||||
@@ -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
|
||||
}
|
||||
@@ -1,13 +1,5 @@
|
||||
#!/bin/sh
|
||||
# ------------------------------------------------------------
|
||||
# Mise à jour système – version POSIX sh
|
||||
# ------------------------------------------------------------
|
||||
#!/bin/bash
|
||||
|
||||
<<<<<<< HEAD
|
||||
# -e : quitter dès la première erreur
|
||||
# -u : erreur lorsqu'une variable n'est pas définie
|
||||
set -eu
|
||||
=======
|
||||
###############################################################
|
||||
# name: MAJ.ksh
|
||||
# Description : Automatise les mises a jours Paquets + OS
|
||||
@@ -19,7 +11,6 @@ set -eu
|
||||
# Date de création : 19/04/2023
|
||||
#
|
||||
###############################################################
|
||||
>>>>>>> main
|
||||
|
||||
# ---------- Couleurs (facultatives) ----------
|
||||
# Certaines consoles ne supportent pas tput, on prévoit un fallback vide.
|
||||
@@ -65,7 +56,6 @@ upgrade_installed() {
|
||||
run_cmd apt-get upgrade -y
|
||||
}
|
||||
|
||||
<<<<<<< HEAD
|
||||
dist_upgrade_os() {
|
||||
log INFO "Dist-upgrade de l’OS…"
|
||||
run_cmd apt-get dist-upgrade -y
|
||||
@@ -82,7 +72,8 @@ clean_cache() {
|
||||
}
|
||||
|
||||
# ---------- Point d’entrée ----------
|
||||
main() {
|
||||
main()
|
||||
{
|
||||
update_pkg_list
|
||||
upgrade_installed
|
||||
dist_upgrade_os
|
||||
@@ -93,6 +84,3 @@ main() {
|
||||
|
||||
# Lancer le script
|
||||
main "$@"
|
||||
=======
|
||||
echo "Mise à jour terminée avec succès."
|
||||
>>>>>>> main
|
||||
Whitespace-only changes.
Reference in new issue
Block a user