# Check the devices and it's partitions: lsblk to check # If under /dev/sdc and mounted: sudo umount /dev/sdc1 # Put the OS image on the USB stick: sudo dd if=nixos.iso of=/dev/sdc # # Derived from https://www.maketecheasier.com/nixos-review/ # First, get an internet connection, either by using an ethernet cable or using =wpa_supplicant=: # https://wiki.archlinux.org/index.php/WPA_supplicant wpa_supplicant -B -i wlp2s0 -c <(wpa_passphrase SSID PASSPHRASE) # Change keyboard to pt_BR layout: loadkeys br-abnt2 # Format disk: fdisk /dev/sda # START Steps within fdisk d # first, delete all partitions with `d` o n p 1 ENTER +4G t 82 n p 2 ENTER ENTER a 2 w # END Steps within fdisk mkswap -L swap /dev/sda1 swapon /dev/sda1 mkfs.ext4 -L nixos /dev/sda2 mount /dev/disk/by-label/nixos /mnt nixos-generate-config --root /mnt # START Edit NixOS configuration file vi /mnt/etc/nixos/configuration.nix # Uncomment: boot.loader.grub.device = “/dev/sda” enviroment.systemPackages = with pkgs; [ wget vim firefox gitAndTools.gitFull gitAndTools.git-annex gitAndTools.gitRemoteGcrypt lsof gnupg gnupg1 ] # Add: services = { xserver = { enable = true; desktopManager.gnome3.enable = true; displayManager.gdm.enable = true; }; }; # END nixos-install # OS will prompt for root UNIX password reboot C-M- useradd -m andreh passwd andreh # Setup UNIX password (for andreh) sudo vi /etc/sudoers # START Add the following line below the `root` line andreh ALL=(ALL) ALL # END