2024-08-25 19:58:12 +00:00
# My NixOS Flake
2024-02-07 13:14:55 +00:00
2024-08-25 19:58:12 +00:00
This repository contains my personal NixOS configurations for two machines: my laptop (`vamos`) and my desktop computer (`solaire`). These configurations are managed using the Nix Flake system to ensure reproducibility and ease of deployment.
2024-02-07 13:14:55 +00:00
2024-08-25 19:58:12 +00:00
## Structure
2024-02-07 13:14:27 +00:00
2024-08-25 19:58:12 +00:00
- `flake.nix` : The main entry point for the Nix flake.
- `hosts/` : Directory containing the specific configurations for each host (`vamos` and `solaire` ).
- `modules/` : Reusable NixOS modules shared between different configurations.
- `home/` : Userspace configuration, divided between laptop and desktop.
2024-02-07 13:15:27 +00:00
2024-08-25 19:58:12 +00:00
## Hosts
2024-02-07 13:15:27 +00:00
2024-08-25 19:58:12 +00:00
### Vamos (Laptop)
2024-02-07 14:45:56 +00:00
2024-08-25 19:58:12 +00:00
This is the configuration for my laptop, `vamos` . It uses Gnome, and includes settings optimized for power management, and lightweight applications.
2023-09-20 16:27:06 +00:00
2024-08-25 19:58:12 +00:00
### Solaire (Desktop)
2024-02-07 14:45:56 +00:00
2024-08-25 19:58:12 +00:00
This is the configuration for my desktop computer, `solaire` . It also uses Gnome, and adds Nvidia drivers.
2024-02-07 14:45:56 +00:00
2024-08-25 19:58:12 +00:00
## Usage
2024-02-07 14:36:27 +00:00
2024-08-25 19:58:12 +00:00
### Applying the Configuration
2024-02-07 14:36:27 +00:00
2024-08-25 19:58:12 +00:00
To apply the configuration on a machine, use the following steps:
2024-02-07 14:36:27 +00:00
2024-08-25 19:58:12 +00:00
1. Clone this repository:
2024-02-07 14:36:27 +00:00
2024-08-25 19:58:12 +00:00
```bash
2024-08-25 20:24:50 +00:00
git clone https://github.com/nezia1/dotfiles.git .dotfiles
cd .dotfiles
2024-08-25 19:58:12 +00:00
```
2023-09-20 16:27:06 +00:00
2024-08-25 19:58:12 +00:00
2. Switch to the desired configuration:
2024-02-07 15:01:04 +00:00
2024-08-25 19:58:12 +00:00
```bash
sudo nixos-rebuild switch --flake .#< hostname >
```
2023-09-20 16:27:06 +00:00
2024-08-25 19:58:12 +00:00
Replace `<hostname>` with either `vamos` or `solaire` depending on the machine you are configuring.
2023-09-20 16:27:06 +00:00
2024-08-25 19:58:12 +00:00
### Example
2023-09-20 16:27:06 +00:00
2024-08-25 19:58:12 +00:00
For the laptop (`vamos`):
2023-09-20 16:27:06 +00:00
2024-08-25 19:58:12 +00:00
```bash
sudo nixos-rebuild switch --flake .#vamos
```
2023-09-20 16:27:06 +00:00
2024-08-25 19:58:12 +00:00
For the desktop (`solaire`):
2024-02-07 13:11:58 +00:00
2024-08-25 19:58:12 +00:00
```bash
sudo nixos-rebuild switch --flake .#solaire
```
2024-02-07 13:11:58 +00:00
2024-08-25 19:58:12 +00:00
## License
2023-09-20 16:27:06 +00:00
2024-08-25 19:58:12 +00:00
This repository is licensed under the MIT License. See the [LICENSE ](LICENSE ) file for details.