Profiles:
- OS: NixOS
- Window Manager:
- Hyprland
- Shell::
- ZSH
- Terminal::
- Kitty
- Editor:
- Neovim
- Visual Studio Code
- Shell:
- Nodejs
- Flake: configurations for code formatting, and pre-commit hooks.
- Home: Home-Manager configurations.
- Hosts: Configurations specific to individual hosts.
- Lib: Personal library and utilities.
- Modules: Shared system-wide modules.
- pkgs: Customized and additional packages.
- shells Shell templates to reuse
After boot to Nix installation.
systemctl start wpa_supplicant
wpa_cli
scan
add_network
set_network 0 ssid "wifi-name"
set_network 0 psk "wifi-password"
enable_network 0
save_config
reconnect
Then CTRL-D
to exit.
nix-shell -p git
git clone https://ducnguyen96/gorgeos
- Modify disko-config as you want. Full guide here
- Run
./misc/disko/run
You can cp hosts/e14g2 to your own host for example:
cp -r hosts/e14g2 hosts/8570w
Then generate your hardware config
nixos-generate-config --root /mnt
Copy the hardware config to your host
cp /mnt/etc/nixos/hardware-configuration.nix hosts/8570w
Add your host to the flake
[!NOTE]: Replace user below with your user home-manager.users.<your-user>.imports = ...
hosts/default.nix
{
homeImports,
inputs,
self,
themes,
...
}: let
inherit (inputs.nixpkgs.lib) nixosSystem;
modules = "${self}/modules/system";
hardware = modules + "/hardware";
profiles = "${self}/hosts/profiles";
specialArgs = {inherit inputs self themes;};
in {
flake.nixosConfigurations = {
8570w = nixosSystem {
inherit specialArgs;
modules = [
./8570w
"${modules}/config"
"${modules}/programs"
"${modules}/security"
"${modules}/services"
"${modules}/virtualization/docker.nix"
"${hardware}/bluetooth.nix"
"${hardware}/intel.nix"
"${hardware}/amd.nix"
"${profiles}/hyprland"
{
home-manager = {
users.duc.imports = homeImports."duc@hyprland";
extraSpecialArgs = specialArgs;
};
}
];
};
};
}
Replace the user in:
You can modify the existing profile or add a new profile as follow:
touch home/profiles/new-profile.nix
Add the profile to the flex
home/default.nix
flake = {
homeConfigurations = withSystem "x86_64-linux" ({pkgs, ...}: {
"duc@hyprland" = homeManagerConfiguration {
inherit pkgs;
modules = homeImports."duc@hyprland";
};
"new-profile" = homeManagerConfiguration {
inherit pkgs;
};
});
};
Then you can use the profile for your host
hosts/default.nix
8570w = nixosSystem {
modules =
[
./8570w
../modules/hardware/audio
../modules/hardware/gpu/intel.nix
self.nixosModules.hyprland
{home-manager.users.<your-user>.imports = homeImports."new-profile";}
];
};
After updating host and home as you like you can install the whole thing with
8570w
here is your host
nixos-install --flake .#8570w
It will take a while. Then after that you can reboot.
# note that rebuild script assume your flake is in the same directory as this repo which is ~/Documents/Code/gorgeos
rebuild
sudo nix-collect-garbage -d
nix-collect-garbage -d