Skip to content

Configuration for NixOS and home-manager, integrated with flakes

License

Notifications You must be signed in to change notification settings

henry40408/nixos-config

Repository files navigation

nixos-config

Casual Maintenance Intended GitHub Workflow Status (with event) GitHub

Description

This repository, maintained by henry40408, features configurations managed with Nix Flakes. It is organized into "home-manager" and "hosts" directories for home-manager and NixOS configurations, respectively. The project is based on the template provided by Misterio77's nix-starter-configs and is designed for both WSL and VM environments.

Installation

Ensure Nix with Flake support is installed. Clone this repository:

git clone https://github.com/henry40408/nixos-config.git
cd nixos-config

To ensure that the NixOS configuration is evaluable, also known as a dry run:

make os/dry-run

To deploy the NixOS configuration:

(Recommended) Automatically apply the configuration based on the detected environment:

make os/switch

For WSL:

sudo nixos-rebuild switch --flake .#wsl

For VM:

Ensure the VM boots with UEFI and has three partitions labeled "boot", "nixos", and "swap". For detailed setup instructions, consult the NixOS Manual.

sudo nixos-rebuild switch --flake .#vm

To ensure that the Home Manager configuration is evaluable, also known as a dry run:

make dry-run

To apply the home-manager configuration:

home-manager switch --flake .#nixos@all
# or
make switch

Usage

The "home-manager" directory contains user-level settings, and the "hosts" directory includes system-level configurations for different NixOS hosts. Customize by editing these files. The Flake.nix file orchestrates their integration and management. For more details, please refer to ARCHITECTURE.md

Contributing

Contributions are welcome. Please review our contributing guidelines for proposing changes.

License

Licensed under the MIT License.

About

Configuration for NixOS and home-manager, integrated with flakes

Resources

License

Stars

Watchers

Forks