mirror of
https://gitlab.com/ahoneybun/nyxi-installer.git
synced 2025-05-12 11:04:02 -06:00
Clean up comments in the code to make it more readable hopefully
This commit is contained in:
parent
fb7de0dbe8
commit
1641a786f0
1 changed files with 9 additions and 16 deletions
25
install.sh
25
install.sh
|
@ -5,8 +5,9 @@ ramTotal=$(free -h | awk '/^Mem:/{print $2}'| awk -FG {'print$1'})
|
||||||
# Detect and list the drives.
|
# Detect and list the drives.
|
||||||
lsblk -f
|
lsblk -f
|
||||||
|
|
||||||
|
# Step 1: Choosing the drive for the installation
|
||||||
|
|
||||||
# Choice the drive to use :
|
# Choice the drive to use :
|
||||||
# 1.
|
|
||||||
echo "----------"
|
echo "----------"
|
||||||
echo "Which drive do we want to use for this installation?"
|
echo "Which drive do we want to use for this installation?"
|
||||||
read driveName
|
read driveName
|
||||||
|
@ -18,6 +19,8 @@ curl https://gitlab.com/ahoneybun/nix-configs/-/raw/main/partitions/luks-btrfs-s
|
||||||
# Replace drive in Disko file
|
# Replace drive in Disko file
|
||||||
sudo sed -i "s#/dev/sda#$driveName#g" /tmp/disko-config.nix
|
sudo sed -i "s#/dev/sda#$driveName#g" /tmp/disko-config.nix
|
||||||
|
|
||||||
|
# Step 2: Partitioning the drive used for the installation
|
||||||
|
|
||||||
# Run Disko to partition the disk
|
# Run Disko to partition the disk
|
||||||
sudo nix --experimental-features "nix-command flakes" run github:nix-community/disko -- --mode disko /tmp/disko-config.nix
|
sudo nix --experimental-features "nix-command flakes" run github:nix-community/disko -- --mode disko /tmp/disko-config.nix
|
||||||
|
|
||||||
|
@ -25,16 +28,10 @@ sudo nix --experimental-features "nix-command flakes" run github:nix-community/d
|
||||||
sudo nixos-generate-config --no-filesystems --root /mnt
|
sudo nixos-generate-config --no-filesystems --root /mnt
|
||||||
sudo mv /tmp/disko-config.nix /mnt/etc/nixos
|
sudo mv /tmp/disko-config.nix /mnt/etc/nixos
|
||||||
|
|
||||||
# Copy my base nix configs over
|
# Downloads and places the predefinded generic flake to use
|
||||||
# Change the URL to match where you are hosting your .nix file(s).
|
|
||||||
|
|
||||||
echo ""
|
|
||||||
echo "Default username and password are in the flake.nix file"
|
|
||||||
echo "Password is hashed so it is not plaintext"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
curl https://gitlab.com/ahoneybun/nix-configs/-/raw/flake/flake.nix > flake.nix; sudo mv -f flake.nix /mnt/etc/nixos/
|
curl https://gitlab.com/ahoneybun/nix-configs/-/raw/flake/flake.nix > flake.nix; sudo mv -f flake.nix /mnt/etc/nixos/
|
||||||
#curl https://gitlab.com/ahoneybun/nix-configs/-/raw/main/programs.nix > programs.nix; sudo mv -f programs.nix /mnt/etc/nixos/
|
|
||||||
|
# Step 3: Choosing a predefined system flake file to use
|
||||||
|
|
||||||
cat << EOF
|
cat << EOF
|
||||||
|
|
||||||
|
@ -50,9 +47,6 @@ Which device are you installing to?
|
||||||
EOF
|
EOF
|
||||||
read deviceChoice
|
read deviceChoice
|
||||||
|
|
||||||
# Change the URL to match where you are hosting your system .nix file
|
|
||||||
# Update the second command to the file name that matches your system .nix file
|
|
||||||
|
|
||||||
if [ $deviceChoice = 1 ]; then
|
if [ $deviceChoice = 1 ]; then
|
||||||
curl https://gitlab.com/ahoneybun/nix-configs/-/raw/main/systems/x86_64/shepard/configuration.nix > shepard.nix; sudo mv -f shepard.nix /mnt/etc/nixos
|
curl https://gitlab.com/ahoneybun/nix-configs/-/raw/main/systems/x86_64/shepard/configuration.nix > shepard.nix; sudo mv -f shepard.nix /mnt/etc/nixos
|
||||||
sudo sed -i "11 i \ ./shepard.nix" /mnt/etc/nixos/configuration.nix
|
sudo sed -i "11 i \ ./shepard.nix" /mnt/etc/nixos/configuration.nix
|
||||||
|
@ -85,6 +79,8 @@ elif [ $deviceChoice = 0 ]; then
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Step 4: Choosing a predefined desktop/window manager file to use
|
||||||
|
|
||||||
cat << EOF
|
cat << EOF
|
||||||
|
|
||||||
Which Desktop Environment do you want?
|
Which Desktop Environment do you want?
|
||||||
|
@ -96,9 +92,6 @@ Which Desktop Environment do you want?
|
||||||
EOF
|
EOF
|
||||||
read desktopChoice
|
read desktopChoice
|
||||||
|
|
||||||
# Change the URL to match where you are hosting your DE/WM .nix file
|
|
||||||
# Update the second command to the file name that matches your DE/WM .nix file
|
|
||||||
|
|
||||||
if [ $desktopChoice = 1 ]; then
|
if [ $desktopChoice = 1 ]; then
|
||||||
curl https://gitlab.com/ahoneybun/nix-configs/-/raw/main/desktops/plasma.nix > plasma.nix; sudo mv -f plasma.nix /mnt/etc/nixos/
|
curl https://gitlab.com/ahoneybun/nix-configs/-/raw/main/desktops/plasma.nix > plasma.nix; sudo mv -f plasma.nix /mnt/etc/nixos/
|
||||||
sudo sed -i "10 i \ ./plasma.nix" /mnt/etc/nixos/configuration.nix
|
sudo sed -i "10 i \ ./plasma.nix" /mnt/etc/nixos/configuration.nix
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue