Improve Installation MASSIVELY

This commit is contained in:
Tyler Kelley 2024-02-11 23:35:45 -06:00
parent a307eb43d0
commit 1b8fff179b
4 changed files with 32 additions and 24 deletions

View File

@ -25,20 +25,14 @@ nix = {
}; };
``` ```
This file should be located at /etc/nixos/configuration.nix - Run this command to ensure Git is installed.
- Ensure you have Git listed in your pkgs in the /etc/nixos/configuration.nix file.
- Change the hostname in the /etc/nixos/configuration.nix file.
- Rebuild your system.
``` ```
sudo nixos-rebuild switch nix-shell -p git
``` ```
- Reboot your system.
- Clone this repo. - Clone this repo.
- Then go into repo folder (stay in this folder). - Then go into repo folder (stay in this folder).
- Change username and hostname in flake.nix file.
- Change all options in options.nix as needed. - Change all options in options.nix as needed.
- Generate your hardware.nix like so: - Generate your hardware.nix like so:
@ -46,12 +40,15 @@ sudo nixos-rebuild switch
nixos-generate-config --show-hardware-config > hardware.nix nixos-generate-config --show-hardware-config > hardware.nix
``` ```
- Run this command: - Run this to enable flakes and install the flake:
``` ```
sudo nixos-rebuild switch --flake . NIX_CONFIG="experimental-features = nix-command flakes" \
sudo nixos-rebuild switch --flake .#zaney
``` ```
- Run this command:
Now when you want to rebuild the configuration you have access to an alias called flake-rebuild that will rebuild the flake based of the flakeDir variable you set in options.nix! Now when you want to rebuild the configuration you have access to an alias called flake-rebuild that will rebuild the flake based of the flakeDir variable you set in options.nix!
Hope you enjoy! Hope you enjoy!

View File

@ -7,7 +7,7 @@ let
browser cpuType gpuType browser cpuType gpuType
wallpaperDir borderAnim wallpaperDir borderAnim
theKBDLayout terminal theKBDLayout terminal
theSecondKBDLayout; theSecondKBDLayout sdl-videodriver;
in with lib; { in with lib; {
wayland.windowManager.hyprland = { wayland.windowManager.hyprland = {
enable = true; enable = true;
@ -51,7 +51,7 @@ in with lib; {
env = XDG_SESSION_DESKTOP, Hyprland env = XDG_SESSION_DESKTOP, Hyprland
env = GDK_BACKEND, wayland env = GDK_BACKEND, wayland
env = CLUTTER_BACKEND, wayland env = CLUTTER_BACKEND, wayland
env = SDL_VIDEODRIVER, wayland env = SDL_VIDEODRIVER, ${sdl-videodriver}
env = XCURSOR_SIZE, 24 env = XCURSOR_SIZE, 24
env = XCURSOR_THEME, Bibata-Modern-Ice env = XCURSOR_THEME, Bibata-Modern-Ice
env = QT_QPA_PLATFORM, wayland env = QT_QPA_PLATFORM, wayland

View File

@ -2,7 +2,7 @@
let let
palette = config.colorScheme.palette; palette = config.colorScheme.palette;
inherit (import ../../options.nix) slickbar clock24h; inherit (import ../../options.nix) slickbar simplebar clock24h;
in with lib; { in with lib; {
# Configure & Theme Waybar # Configure & Theme Waybar
programs.waybar = { programs.waybar = {
@ -12,11 +12,15 @@ in with lib; {
layer = "top"; layer = "top";
position = "top"; position = "top";
modules-left = [ "custom/startmenu" "hyprland/window" ]; modules-center = if simplebar == true then [ "hyprland/window" ]
modules-center = [ "network" "pulseaudio" "cpu" "hyprland/workspaces" "memory" "disk" "clock" ]; else [ "network" "pulseaudio" "cpu" "hyprland/workspaces" "memory" "disk" "clock" ];
modules-right = [ "idle_inhibitor" "custom/themeselector" "custom/notification" "battery" "tray" ]; modules-left = if simplebar == true then ["custom/startmenu" "hyprland/workspaces" "cpu" "memory" "network" ]
else [ "custom/startmenu" "hyprland/window" ];
modules-right = if simplebar == true then [ "idle_inhibitor" "custom/themeselector" "custom/notification" "pulseaudio" "clock" "tray" ]
else [ "idle_inhibitor" "custom/themeselector" "custom/notification" "battery" "tray" ];
"hyprland/workspaces" = { "hyprland/workspaces" = {
format = "{icon}"; format = if simplebar == true then "{name}" else "{icon}";
format-icons = { format-icons = {
default = " "; default = " ";
active = " "; active = " ";
@ -216,12 +220,12 @@ in with lib; {
border-radius: 15px; border-radius: 15px;
color: #${palette.base00}; color: #${palette.base00};
background: linear-gradient(45deg, #${palette.base0D}, #${palette.base0E}); background: linear-gradient(45deg, #${palette.base0D}, #${palette.base0E});
opacity: 1.0; opacity: 0.8;
'' else '' '' else ''
border-radius: 10px; border-radius: 10px;
color: #${palette.base00}; color: #${palette.base00};
background: linear-gradient(45deg, #${palette.base06}, #${palette.base0E}); background: linear-gradient(45deg, #${palette.base06}, #${palette.base0E});
opacity: 1.0; opacity: 0.8;
''} ''}
} }
tooltip { tooltip {

View File

@ -5,9 +5,13 @@
let let
username = "zaney"; username = "zaney";
hostname = "hyprnix"; hostname = "hyprnix";
# This is for running NixOS
# On a tmpfs or root on RAM
# You Most Like Want This -> false
impermanence = true;
userHome = "/home/${username}"; userHome = "/home/${username}";
flakeDir = #"${userHome}/zaneyos"; flakeDir = if impermanence == false then "${userHome}/zaneyos"
"/nix/persist/etc/nixos/zaneyos"; else "/nix/persist/etc/nixos/zaneyos";
in { in {
# User Variables # User Variables
username = "${username}"; username = "${username}";
@ -16,9 +20,11 @@ in {
gitEmail = "tylerzanekelley@gmail.com"; gitEmail = "tylerzanekelley@gmail.com";
theme = "gigavolt"; theme = "gigavolt";
slickbar = true; slickbar = true;
simplebar = false; # DO NOT ENABLE!
borderAnim = true; borderAnim = true;
browser = "firefox"; browser = "firefox";
wallpaperGit = "https://gitlab.com/Zaney/my-wallpapers.git"; wallpaperGit = "https://gitlab.com/Zaney/my-wallpapers.git"; # This will give you my wallpapers
# ^ (use as is or replace with your own repo - removing will break the wallsetter script)
wallpaperDir = "${userHome}/Pictures/Wallpapers"; wallpaperDir = "${userHome}/Pictures/Wallpapers";
screenshotDir = "${userHome}/Pictures/Screenshots"; screenshotDir = "${userHome}/Pictures/Screenshots";
flakeDir = "${flakeDir}"; flakeDir = "${flakeDir}";
@ -32,8 +38,9 @@ in {
theLCVariables = "en_US.UTF-8"; theLCVariables = "en_US.UTF-8";
theTimezone = "America/Chicago"; theTimezone = "America/Chicago";
theShell = "bash"; # Possible options: bash, zsh theShell = "bash"; # Possible options: bash, zsh
theKernel = "default"; # possible options: default, latest, lqx, xanmod, zen theKernel = "default"; # Possible options: default, latest, lqx, xanmod, zen
impermanence = true; impermanence = true; # This should be set to false unless you know what your doing!
sdl-videodriver = "x11"; # Either x11 or wayland ONLY. Games might require x11 set here
# For Hybrid Systems intel-nvidia # For Hybrid Systems intel-nvidia
# Should Be Used As gpuType # Should Be Used As gpuType
cpuType = "intel"; cpuType = "intel";