Skip to content

Commit

Permalink
Merge pull request #24 from Niklas20114552/testing
Browse files Browse the repository at this point in the history
Update to v.1.62
  • Loading branch information
Niklas20114552 authored May 15, 2023
2 parents 9bd590a + 2caf6d8 commit fec0fa2
Show file tree
Hide file tree
Showing 8 changed files with 246 additions and 68 deletions.
116 changes: 85 additions & 31 deletions 2step
Original file line number Diff line number Diff line change
Expand Up @@ -2,62 +2,99 @@
# SCRIPT - Installation Script
# Installation-Modes:
# 2Step
function part_cfdisk() {
umount $ndrive*
cfdisk $ndrive
if [[ $extparted = *"multiple-drives"* ]]; then
x1=$(dialog --no-cancel --title "$tit7b" --menu "$lan35" 0 0 0 partition "$but8" continue "$but9" 3>&1 1>&2 2>&3 3>&-)
if [[ $x1 == partition ]]; then
ndrive=$(dialog --cr-wrap --no-collapse --no-cancel --no-items --title "$tit6" --menu "$lan10 \n\n$(lsblk --output NAME,MODEL,PARTTYPENAME,SIZE /dev/{vd*[!0-9],sd*[!0-9],hd*[!0-9],nvme0n[0-9]})" 0 0 0 $drives 3>&1 1>&2 2>&3 3>&-)
part_cfdisk
fi
fi
}
function part_manual() {
extparted=$(dialog --nocancel --title "$tit15" --checklist "$lan36" 0 0 0 "multiple-drives" "$lan37" off "separate-home" "$lan38" off 3>&1 1>&2 2>&3 3>&-)
if [[ -d /sys/firmware/efi ]]; then
dialog --cr-wrap --title "$tit7a $boot_drive" --msgbox "$lan11" 0 0
else
dialog --cr-wrap --title "$tit7a $boot_drive" --msgbox "$lan12" 0 0
fi
cfdisk $boot_drive
if [[ $nvme == true ]]; then
partition=$(find $boot_drive* -name '*p[0-9]' | tr "\n" " ")
partition=$(echo $partition)
if [[ "$partition" == "" ]]; then
partition=$(find "$boot_drive"* -name '*p[0-9]' | tr "\n" " ")
ndrive=$boot_drive
part_cfdisk
# Just to fix some problems with lsblk
lsblk $o6 --output NAME,PARTTYPENAME,FSTYPE,SIZE
if [[ $extparted = *"multiple-drives"* ]]; then
partition=$(find /dev/sd* -name '*[0-9]'; find /dev/nvme* -name '*p[0-9]'; find /dev/hd* -name '*[0-9]'; find /dev/vd* -name "*[0-9]")
partition=$(echo $partition | tr "\n" " ")
partlsblk=$(lsblk $drives --output NAME,PARTTYPENAME,FSTYPE,SIZE)
else
partlsblk=$(lsblk $o6 --output NAME,PARTTYPENAME,FSTYPE,SIZE)
if [[ $nvme == true ]]; then
partition=$(find $boot_drive* -name '*p[0-9]' | tr "\n" " ")
partition=$(echo $partition)
if [[ "$partition" == "" ]]; then
dialog --cr-wrap --title "$err2" --msgbox "$err4a $boot_drive $err4b" 0 0
exit
partition=$(find "$boot_drive"* -name '*p[0-9]' | tr "\n" " ")
partition=$(echo $partition)
if [[ "$partition" == "" ]]; then
dialog --cr-wrap --title "$err2" --msgbox "$err4a $boot_drive $err4b" 0 0
exit
fi
fi
fi
else
partition=$(find $boot_drive* -name '*[0-9]' | tr "\n" " ")
partition=$(echo $partition)
if [[ "$partition" == "" ]]; then
partition=$(find "$boot_drive"* -name '*[0-9]' | tr "\n" " ")
else
partition=$(find $boot_drive* -name '*[0-9]' | tr "\n" " ")
partition=$(echo $partition)
if [[ "$partition" == "" ]]; then
dialog --cr-wrap --title "$err2" --msgbox "$err4a $boot_drive $err4b" 0 0
exit
partition=$(find "$boot_drive"* -name '*[0-9]' | tr "\n" " ")
partition=$(echo $partition)
if [[ "$partition" == "" ]]; then
dialog --cr-wrap --title "$err2" --msgbox "$err4a $boot_drive $err4b" 0 0
exit
fi
fi
fi
fi
lsblk $o6
if [[ -d /sys/firmware/efi ]]; then
e1=$(dialog --cr-wrap --no-collapse --no-cancel --no-items --title "$tit7b" --menu "$lan13 \n\n$(lsblk $o6 --output NAME,PARTTYPENAME,FSTYPE,SIZE)" 0 0 0 $partition 3>&1 1>&2 2>&3 3>&-)
e1=$(dialog --cr-wrap --no-collapse --no-cancel --no-items --title "$tit7b" --menu "$lan13 \n\n$partlsblk" 0 0 0 $partition 3>&1 1>&2 2>&3 3>&-)
dialog --cr-wrap --title "$tit8 $e1" --yesno "$lan14" 0 0
if [[ $? == 0 ]]; then
yes | mkfs.vfat $e1
yes | mkfs.vfat $e1
fi
fi
o7=$(dialog --cr-wrap --no-collapse --no-cancel --no-items --title "$tit7b" --menu "$lan17 \n\n$(lsblk $o6 --output NAME,PARTTYPENAME,FSTYPE,SIZE)" 0 0 0 $partition 3>&1 1>&2 2>&3 3>&-)
o7=$(dialog --cr-wrap --no-collapse --no-cancel --no-items --title "$tit7b" --menu "$lan17 \n\n$partlsblk" 0 0 0 $partition 3>&1 1>&2 2>&3 3>&-)
fs=$(dialog --cr-wrap --no-items --no-cancel --title "$tit7b" --menu "$lan33" 0 0 0 btrfs ext4 3>&1 1>&2 2>&3 3>&-)
case $fs in
btrfs) extp="grub-btrfs" ;;
btrfs) extp="grub-btrfs btrfs-progs" ;;
esac
dialog --cr-wrap --title "$tit8 $o7" --default-button no --yesno "$lan18" 0 0
if [[ $? == 1 ]]; then
dialog --cr-wrap --title "$err3" --msgbox "$err5" 0 0
dialog --cr-wrap --title "$err2" --msgbox "$err5" 0 0
exit
fi
case $fs in
ext4) yes | mkfs.ext4 $o7 ;;
btrfs) mkfs.btrfs --force $o7 ;;
esac
dialog --cr-wrap --title "$tit9" --yesno "$lan15" 0 0
if [[ $extparted = *"separate-home"* ]]; then
x2=$(dialog --cr-wrap --no-collapse --no-cancel --no-items --title "$tit7b" --menu "$lan34 \n\n$partlsblk" 0 0 0 $partition 3>&1 1>&2 2>&3 3>&-)
x2fs=$(dialog --cr-wrap --no-items --no-cancel --title "$tit7b" --menu "$lan33" 0 0 0 btrfs ext4 3>&1 1>&2 2>&3 3>&-)
case $x2fs in
btrfs) extp="grub-btrfs btrfs-progs" ;;
esac
dialog --cr-wrap --title "$tit8 $x2" --default-button no --yesno "$lan18" 0 0
if [[ $? == 1 ]]; then
dialog --cr-wrap --title "$err2" --msgbox "$err5" 0 0
exit
fi
case $x2fs in
ext4) yes | mkfs.ext4 $x2 ;;
btrfs) mkfs.btrfs --force $x2 ;;
esac
dialog --cr-wrap --title "$tit9" --yesno "$lan15" 0 0
fi
if [[ $? == 0 ]]; then
swap=yes
o8=$(dialog --cr-wrap --no-collapse --no-cancel --no-items --title "$tit7b" --menu "$lan16 \n\n$(lsblk $o6 --output NAME,PARTTYPENAME,FSTYPE,SIZE)" 0 0 0 $partition 3>&1 1>&2 2>&3 3>&-)
o8=$(dialog --cr-wrap --no-collapse --no-cancel --no-items --title "$tit7b" --menu "$lan16 \n\n$partlsblk" 0 0 0 $partition 3>&1 1>&2 2>&3 3>&-)
yes | mkswap $o8
fi
}
Expand Down Expand Up @@ -225,13 +262,30 @@ fi
dialog --cr-wrap --title "$mtit" --msgbox "$lan23" 0 0
mount "$o7" /target
if [[ $fs == btrfs ]]; then
(cd /target && btrfs subvolume create @ && btrfs subvolume create @home && btrfs subvolume create @var && btrfs subvolume create @snapshots)
umount /target
mount -o noatime,compress=zstd,space_cache=v2,ssd,discard=async,subvol=@ $o7 /target
mkdir -p /target/{home,var,.snapshots}
mount -o noatime,compress=zstd,space_cache=v2,ssd,discard=async,subvol=@home $o7 /target/home
mount -o noatime,compress=zstd,space_cache=v2,ssd,discard=async,subvol=@var $o7 /target/var
mount -o noatime,compress=zstd,space_cache=v2,ssd,discard=async,subvol=@snapshots $o7 /target/.snapshots
btrfs subvolume create /target/@
if [[ $extparted != *"separate-home"* ]]; then
btrfs subvolume create /target/@home
fi
btrfs subvolume create /target/@var
btrfs subvolume create /target/@snapshots
umount /target
mount -o noatime,compress=zstd,space_cache=v2,ssd,discard=async,subvol=@ $o7 /target
mkdir -p /target/{home,var,.snapshots}
if [[ $extparted != *"separate-home"* ]]; then
mount -o noatime,compress=zstd,space_cache=v2,ssd,discard=async,subvol=@home $o7 /target/home
fi
mount -o noatime,compress=zstd,space_cache=v2,ssd,discard=async,subvol=@var $o7 /target/var
mount -o noatime,compress=zstd,space_cache=v2,ssd,discard=async,subvol=@snapshots $o7 /target/.snapshots
fi
if [[ $extparted = *"separate-home"* ]]; then
mkdir -p /target/home
mount "$x2" /target/home
if [[ $x2fs == btrfs ]]; then
echo "Please note: This is not a bug! The Partition will be unmounted later and correctly mounted:"
btrfs subvolume create /target/home/@home
umount /target/home
mount -o noatime,compress=zstd,space_cache=v2,ssd,discard=async,subvol=@home $x2 /target/home
fi
fi
if [[ -d /sys/firmware/efi ]]; then
mkdir -p /target/boot/efi
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Arch-TUI-Installer is an Installer for [Archlinux](https://archlinux.org).

It's based on the [Arch Basic Install](https://gitlab.com/sontypiminternet/arch-basic)-Repository on GitLab.

[![GitHub release (latest by date)](https://img.shields.io/github/v/release/Niklas20114552/arch-tui-installer?display_name=tag&label=Release&style=flat-square)](https://github.com/Niklas20114552/arch-tui-installer/releases/latest)
[![GitHub release](https://img.shields.io/github/v/release/Niklas20114552/arch-tui-installer?display_name=tag&label=Release&style=flat-square)](https://github.com/Niklas20114552/arch-tui-installer/releases/latest)
[![Website](https://img.shields.io/static/v1?label=Website&message=click&color=blue&style=flat-square)](https://arch-tui-installer.github.io)
[![Isomaker](https://img.shields.io/static/v1?label=Isomaker&message=click&color=blue&style=flat-square)](https://github.com/arch-tui-installer/arch-tui-installer-isomaker)

Expand Down
1 change: 1 addition & 0 deletions installed/desktopinstall
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ case $slan in
es) libreoffice=libreoffice-still-es ;;
esac
if [[ $de == kde ]]; then
iaur firefox-appmenu
pacman --ignore konqueror --noconfirm --needed -Sy xorg sddm plasma kde-applications vlc papirus-icon-theme materia-kde archlinux-wallpaper $libreoffice
systemctl enable sddm
elif [[ $de == gnome ]]; then
Expand Down
1 change: 1 addition & 0 deletions installed/installer
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ case $slan in
es) libreoffice=libreoffice-still-es ;;
esac
if [[ $de == kde ]]; then
iaur firefox-appmenu
pacman --ignore konqueror --noconfirm --needed -Sy xorg sddm plasma kde-applications vlc papirus-icon-theme materia-kde archlinux-wallpaper $libreoffice
systemctl enable sddm
elif [[ $de == gnome ]]; then
Expand Down
52 changes: 50 additions & 2 deletions lang.conf
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ if [[ $1 == de ]]; then
lan3="Bitte geben sie das Nutzer Passwort ein: \n\nSie können das Passwort bei der Eingabe nicht sehen!"
lan4="Bitte wiederholen sie das Nutzer Passwort: \n\nSie können das Passwort bei der Eingabe nicht sehen!"
lan5="Die Passwörter stimmen nicht überein"
lan6="Das Setup benötigt einen Internetzugang. \nBitte stellen sie Sicher, dass sie mit den Internet verbunden sind."
lan6="Das Setup benötigt einen Internetzugang. \nBitte stellen Sie Sicher, dass sie mit den Internet verbunden sind."
lan7="Bitte wählen sie ihr Tastatur-Layout:"
lan8="Bitte wählen sie ihre Zeitzone:"
lan9="Bitte geben sie ihren Hostname an:\n\nFalls sie einen von ihren Administrator bekommen haben, geben sie ihn hier ein:\n\nEin Hostname besteht nur aus Zahlen und Buchstaben. Keine Sonderzeichen und Leerzeichen."
lan10="Bitte wählen sie ihre Festplatte"
lan11="Nun müssen sie ihre Platte partitionieren:\n\nSie benötigen eine Partition des Types EFI-System (empf. Größe: 300MB)\nSie benötigen eine Partition des Types Linux filesystem.\nSie können auch eine Swap-Partition erstellen.\n\nFalls sie nach einen Labeltype gefragt werden, wählen sie: GPT"
lan12="Nun müssen sie ihre Platte partitionieren:\n\nSie benötigen eine Bootbare Partition des Types Linux.\nSie können auch eine Swap-Partition erstellen.\n\nFalls sie nach einen Labeltype gefragt werden, wählen sie: DOS"
lan13="Bitte wählen sie EFI-Partition \n(Typ: EFI-System)"
lan14="Wollen sie die Partition formartieren? \nDies ist erforderlich wenn sie die Partition gerade erst erstellt haben. \n\nDurch das formatieren können sie möglicherweise andere Betriebssyteme nicht mehr verwenden."
lan14="Wollen sie die Partition formartieren? \nDies ist erforderlich wenn Sie die Partition gerade erst erstellt haben. \n\nDurch das formatieren können sie möglicherweise andere Betriebssyteme nicht mehr verwenden."
lan15="Haben sie eine Swap-Partition erstellt?"
lan16="Bitte wählen sie die SWAP-Partition"
lan17="Bitte wählen sie die ROOT-Partition \n(Typ: Linux)"
Expand All @@ -33,6 +33,11 @@ if [[ $1 == de ]]; then
lan31="Diese Festplatte wird nun FORMATIERT! \nACHTUNG: Dies ZERSTÖRT ALLE DATEN UND ALLE ANDEREN BETRIEBSSYSTEME AUF DIESER FESTPLATTE!"
lan32="Bitte geben sie an, ob sie bevorzugt Proprietäre Treiber oder Opensource Treiber verwenden?"
lan33="Bitte wählen sie ihr Dateisystem. \nEmpfohlene Wahl: btrfs"
lan34="Bitte wählen sie die HOME-Partition"
lan35="Bitte wählen Sie, was sie als nächstes tun wollen"
lan36="Bitte wählen Sie Ihre gewünschten Einstellungen"
lan37="Mehr als ein Laufwerk für die Installation verwenden"
lan38="Separate Homepartition verwenden"

mtit="Setup"
tit1="Root-Passwort"
Expand All @@ -50,6 +55,7 @@ if [[ $1 == de ]]; then
tit12="Prozessor"
tit13="Desktop auswählen"
tit14="Treiber"
tit15="Erweiterte Partitionierungseinstellungen"

but1="Beenden"
but2="Kein AUR-Helper"
Expand All @@ -60,6 +66,8 @@ if [[ $1 == de ]]; then
but6="Manuell Partitionieren"
but6b="Manuell"
but7="Keinen Desktop installieren"
but8="Partition another drive"
but9="Continue with the setup"

err1="Debug-Modus aktiviert."
err2="KRITISCH"
Expand Down Expand Up @@ -106,6 +114,11 @@ elif [[ $1 == en ]]; then
lan31="This disk will now be FORMATTED! \nWARNING: THIS WILL DESTROY ALL DATA AND ALL OTHER OPERATING SYSTEMS ON THIS DISK!"
lan32="Please choose whether you prefer to use proprietary drivers or open source drivers?"
lan33="Please select your file system. \nRecommended choice: btrfs"
lan34="Please select the HOME partition"
lan35="Please choose what you want to do next"
lan36="Please choose your wanted settings"
lan37="Use more than one Drive for the installation"
lan38="Use separate Homepartition"

mtit="Setup"
tit1="Root-Password"
Expand All @@ -123,6 +136,7 @@ elif [[ $1 == en ]]; then
tit12="CPU"
tit13="Choose desktop"
tit14="Drivers"
tit15="Advanced Partitioning Settings"

but1="Quit"
but2="No AUR-Helper"
Expand All @@ -133,6 +147,8 @@ elif [[ $1 == en ]]; then
but6="Manual partition"
but6b="Manual"
but7="Do not install a desktop"
but8="Partition another drive"
but9="Continue with the setup"

err1="Debug-Mode activated."
err2="CRITICAL"
Expand Down Expand Up @@ -179,6 +195,11 @@ elif [[ $1 == fr ]]; then
lan31="Ce disque ne sera PAS FORMATÉ!\nAVERTISSEMENT: CELA DÉTRUIT TOUTES LES DONNÉES ET TOUS LES AUTRES SYSTÈMES D'EXPLOITATION SUR CE DISQUE!"
lan32="Please choose whether you prefer to use proprietary drivers or open source drivers?"
lan33="Please select your file system. \nRecommended choice: btrfs"
lan34="Please select the HOME partition"
lan35="Please choose what you want to do next"
lan36="Please choose your wanted settings"
lan37="Use more than one Drive for the installation"
lan38="Use separate Homepartition"

mtit="Assistant de configuration"
tit1="Mot de passe de root"
Expand All @@ -196,6 +217,7 @@ elif [[ $1 == fr ]]; then
tit12="Processeur"
tit13="Sélectionnez le bureau"
tit14="Drivers"
tit15="Advanced Partitioning Settings"

but1="Quitter"
but2="Pas d'AUR-Helper"
Expand All @@ -206,6 +228,8 @@ elif [[ $1 == fr ]]; then
but6="Partition manuelle"
but6b="Manuel"
but7="N'installez pas d'environnement de bureau"
but8="Partition another drive"
but9="Continue with the setup"

err1="Mode débogage activé."
err2="CRUCIAL"
Expand Down Expand Up @@ -252,6 +276,11 @@ elif [[ $1 == nl ]]; then
lan31="Deze schijf wordt nu GEFORMATTEERD! \nWAARSCHUWING: DIT VERNIETIGT ALLE GEGEVENS EN ALLE ANDERE BESTURINGSSYSTEMEN OP DEZE SCHIJF!"
lan32="Please choose whether you prefer to use proprietary drivers or open source drivers?"
lan33="Please select your file system. \nRecommended choice: btrfs"
lan34="Please select the HOME partition"
lan35="Please choose what you want to do next"
lan36="Please choose your wanted settings"
lan37="Use more than one Drive for the installation"
lan38="Use separate Homepartition"

mtit="Setup"
tit1="Root-wachtwoord"
Expand All @@ -269,6 +298,7 @@ elif [[ $1 == nl ]]; then
tit12="processor"
tit13="Seleziona scrivania"
tit14="Drivers"
tit15="Advanced Partitioning Settings"

but1="Beëindigen"
but2="Geen AUR-Helper"
Expand All @@ -279,6 +309,8 @@ elif [[ $1 == nl ]]; then
but6="Handmatige partitie"
but6b="Handmatig"
but7="Installeer geen desktopomgeving"
but8="Partition another drive"
but9="Continue with the setup"

err1="Debug-modus geactiveerd."
err2="KRITISCHE"
Expand Down Expand Up @@ -325,6 +357,11 @@ elif [[ $1 == it ]]; then
lan31="Questo disco sarà ora FORMATTATO! \nATTENZIONE: QUESTO DISTRUGGERA' TUTTI I DATI E TUTTI GLI ALTRI SISTEMI OPERATIVI SU QUESTO DISCO!"
lan32="Please choose whether you prefer to use proprietary drivers or open source drivers?"
lan33="Please select your file system. \nRecommended choice: btrfs"
lan34="Please select the HOME partition"
lan35="Please choose what you want to do next"
lan36="Please choose your wanted settings"
lan37="Use more than one Drive for the installation"
lan38="Use separate Homepartition"

mtit="Impostare"
tit1="Password di root"
Expand All @@ -342,6 +379,7 @@ elif [[ $1 == it ]]; then
tit12="processore"
tit13="Seleccionar escritorio"
tit14="Drivers"
tit15="Advanced Partitioning Settings"

but1="smettere"
but2="Nessun AUR-Helper"
Expand All @@ -352,6 +390,8 @@ elif [[ $1 == it ]]; then
but6="Partizione manuale"
but6b="Manuale"
but7="Non installare un desktop"
but8="Partition another drive"
but9="Continue with the setup"

err1="Modalità di debug attivata."
err2="CRITICO"
Expand Down Expand Up @@ -398,6 +438,11 @@ elif [[ $1 == es ]]; then
lan31="¡Este disco ahora será FORMATEADO! \nADVERTENCIA: ¡ESTO DESTRUIRÁ TODOS LOS DATOS Y TODOS LOS DEMÁS SISTEMAS OPERATIVOS EN ESTE DISCO!"
lan32="Please choose whether you prefer to use proprietary drivers or open source drivers?"
lan33="Please select your file system. \nRecommended choice: btrfs"
lan34="Please select the HOME partition"
lan35="Please choose what you want to do next"
lan36="Please choose your wanted settings"
lan37="Use more than one Drive for the installation"
lan38="Use separate Homepartition"

mtit="Configuración"
tit1="Contraseña raíz"
Expand All @@ -415,6 +460,7 @@ elif [[ $1 == es ]]; then
tit12="procesador"
tit13="Choose desktop"
tit14="Drivers"
tit15="Advanced Partitioning Settings"

but1="Marcharse"
but2="Sin AUR-Ayudante"
Expand All @@ -425,6 +471,8 @@ elif [[ $1 == es ]]; then
but6="partición manual"
but6b="Manual"
but7="No instale un entorno de escritorio"
but8="Partition another drive"
but9="Continue with the setup"

err1="Modo de depuración activado."
err2="CRÍTICO"
Expand Down
Loading

0 comments on commit fec0fa2

Please sign in to comment.