Skip to content

Personal Nix and Home-manager Configuration for NixOS Based Systems | Flakes 🚧

License

Notifications You must be signed in to change notification settings

TanvirOnGH/nixos-config

Nix icon

About

My Nix configuration for NixOS based systems.

built with nix

Note

This repository is not meant to be used as a whole, but rather as a reference for my own configuration. I do not recommend using it as is, as it is not meant to be used by anyone else. I do not provide any support for this repository. If you want to use it, you are on your own.

Important

I'll eventually switch to flakes configuration.

Warning

Although nixos.wiki has been mentioned and referenced in many places in this repository, it is not an official documentation, it's user maintained. It's not recommended to use the unofficial wiki, instead use the official wiki. The unofficial wiki is not up-to-date, poorly maintained and may contain incorrect information. Replaced all references to the unofficial wiki with the official wiki.

The official documentation is available at wiki.nixos.org.

Formatter and Linter

alejandra is used to format all the nix files. nixfmt and nixpkgs-fmt both advertise ugly and confusing diffs. It is based on the original style of Nixpkgs, and then they applied the feedback from developers with extensive experience using Nix at scale, producing a very well-grounded style guide.

statix is used to capture and fix anti-patterns in all the nix files.

deadnix is used to scan nix files for dead code and automatically remove unused code.

Channels

nixos https://nixos.org/channels/nixos-unstable
home-manager https://github.com/nix-community/home-manager/archive/master.tar.gz
nur https://github.com/nix-community/NUR/archive/master.tar.gz
emacs https://github.com/nix-community/emacs-overlay/archive/master.tar.gz
haskell https://github.com/input-output-hk/haskell.nix/archive/master.tar.gz
mozilla https://github.com/mozilla/nixpkgs-mozilla/archive/master.tar.gz
ragenix https://github.com/yaxitech/ragenix/archive/main.tar.gz
musnix https://github.com/musnix/musnix/archive/master.tar.gz

Resources

Official Nix/NixOS Search

Packages

  • NixHub - Search over 400K granular versions of nix packages.
  • Nix package versions - Find all versions of a package that were available in a channel and the revision you can download it from.
  • NUR (Nix User Repository) - A community-driven meta repository for Nix packages.

Home Manager

Flakes

  • FlakeHub - Find, install, and publish Nix Flakes.

Configuration

  • MyNixOS - Build and share reproducible software environments with Nix and NixOS.

Functions

  • Noogle - Nix API search engine allowing to search functions based on their types and other attributes.
  • teu5us.github.io/nix-lib - Nix (builtins) & Nixpkgs (lib) Functions docs by teu5us.

Channel

Community/User Packages/Flakes/Overlays

  • NUR - User contributed nix packages.
  • Chaotic-Nyx - Daily bumped bleeding edge packages that aren't yet in Nixpkgs. Created by the makers of Chaotic-AUR.
  • Nix-Gaming - Gaming related stuff for Nix and NixOS.
  • Nixified AI - A Nix flake for many AI projects.
  • nixpkgs-mozilla - Official Mozilla overlay for Nixpkgs.
  • nixpkgs-wayland - Bleeding-edge Wayland packages.

Misc

Notable Mentions

  • home-manager - A system for managing a user environment using the nix. It allows declarative configuration of user specific (non-global) packages and dotfiles.

  • NUR - User contributed nix packages. In contrast to Nixpkgs, packages are built from source and are not reviewed by any Nixpkgs member.

  • chaotic nyx - Nix flake for too much bleeding-edge and unreleased packages. And experimental modules.

  • alejandra - The Uncompromising Nix Code Formatter. It applies the feedback of developers who have used Nix at scale for several years, producing a very well-grounded style guide.

  • statix - lints and suggestions for the nix. Able to highlight anti-patterns in Nix code and fix them.

  • deadnix - Scan Nix files for dead code. Able to automatically remove unused code.

  • trustix - Tool that compares build outputs for a given build input across a group of independent providers to establish trust in software binaries.

  • nix-gaming - Gaming related stuff for Nix and NixOS.

  • musnix - Real-time audio in NixOS.

  • schizofox - Hardened Firefox flake for the delusional and the schizophrenics. Can be used as reference.

  • nixbsd - An unofficial NixOS fork with a FreeBSD kernel.

  • RedNixOS - NixOS-based distro for cybersecurity enthusiasts.

  • Athena-OS - NixOS-based distribution intended to build a new concept of pentesting operating system.

  • SnowflakeOS

  • Lix - Lix is an implementation of the Nix functional package management language.

  • flox - A virtual environment and package manager all in one. Installs packages from nixpkgs.

  • Tvix - Rust implementation of the purely-functional Nix package manager.

  • nix-topology - Automatically generate infrastructure and network diagrams as SVGs directly from your NixOS configurations.

  • agenix - A small and convenient nix library for securely managing and deploying secrets using common public-private SSH key pairs. Age-encrypted secrets for NixOS and Home manager.

  • ragenix - Provides age-encrypted secrets for NixOS systems which live in the Nix store and are decrypted on system activation. A drop-in replacement for agenix.

  • icicle - A gtk4/libadwaita installer for NixOS based distributions.

  • nix-software-center - A simple gtk4/libadwaita software center to easily install and manage nix packages.

  • nixos-conf-editor - A libadwaita/gtk4 app for editing NixOS configurations.

  • styx - An alternate binary substitution mechanism for nix.

  • vulnix - A utility that validates a Nix store for any packages that are reachable from live paths and likely to be affected by vulnerabilities listed in the NVD.

  • nix-sandwich - Implements differential compression for downloading from a nix binary cache.

  • lanzaboote - Tooling for UEFI Secure Boot on NixOS.

  • sops-nix - Atomic, declarative, and reproducible secret provisioning for NixOS based on sops.

  • disko - Declarative disk partitioning and formatting using nix.

  • nix-colors - Modules and schemes to make theming with nix awesome.

  • stylix - System-wide colorscheming and typography for nixos.

Abandon Hope, All Ye Who Enter Here

NixOS Learning Curve Graph