thiagokokada/nix-configs

My Nix{OS} configuration files

NixEmacs LispPythonShellYASnippetnixnixosflakehome-managernix-flake
This is stars and forks stats for /thiagokokada/nix-configs repository. As of 25 Apr, 2024 this repository has 68 stars and 2 forks.

nix-configs My Nix{OS} configuration files Overview nix configuration for my laptops, desktops and more nix flake-powered guaranteed to be reproducible Disclaimer This config is not based on any previous available Flake-based Nix{OS} config, instead I choose to develop my own from the available examples and documentation. Some of the repositories that helped me to build this config: https://github.com/bqv/nixrc https://github.com/colemickens/nixcfg https://github.com/hlissner/dotfiles https://github.com/Mic92/dotfiles https://github.com/nrdxp/nixflk Also, some extra resources and documentation about Flakes: Flakes in NixOS Wiki Nix Flakes blog posts from @eldostra Nix documentation Remember: Flakes is experimental, so you shouldn't try this approach until you have some experience in Nix. Dotfiles This repository also includes my home-manager configuration. It is used to configure home in NixOS systems (using home-manager as a NixOS module) but it should also work in standalone mode. Installation NixOS After following the instructions in manual to prepare the system and partition the disk, run the following process to install: $ sudo git clone https://github.com/thiagokokada/nix-configs/ /mnt/etc/nixos $ sudo chown -R 1000:100 /mnt/etc/nixos # optional if you want to edit your config without root $ nix flake new --template '.#new-host' # if this is a new hardware $ sudo nixos-install --flake /mnt/etc/nixos#hostname After installing it succesfully and rebooting, you can uncomment everything and trigger a rebuild. Remote installations You can also do remote installations by using --target-host flag in nixos-rebuild (from any machine that already has NixOS installed): $ nixos-rebuild switch --flake '.#hostname' --target-host root@hostname --use-substitutes Or if you don't have root access via SSH (keep in kind that the user needs to have sudo permissions instead): $ nixos-rebuild switch --flake '.#hostname' --target-host user@hostname --use-substitutes --use-remote-sudo Another option for a few hosts is to use nixos-anywhere. This need to be a host with disko configured. In this case, you can just run: $ nix run github:numtide/nixos-anywhere -- --flake '.#hostname' root@hostname Home Manager (standalone) Start by installing Nix: $ sh <(curl -L https://nixos.org/nix/install) --daemon To build the Home Manager standalone and activate its configuration, run: $ nix run '.#homeActivations/<hostname>' devShell You can also start a minimal configuration based on my Home-Manager setup by running nix develop --impure. A quick way to have a working shell in any Nix-enabled system is to run: $ nix --experimental-features 'nix-command flakes' develop github:thiagokokada/nix-configs --impure This will bring a zsh setup with some other tooling (like neovim) all self contained inside your shell (once it is closed, everything is gone!). Testing You can build a VM to test NixOS configurations with safety running the command below: $ nix run '.#nixosVMs/<hostname>' Explore You can explore all outputs from this configuration by using: $ nix flake show
Read on GithubGithub Stats Page
repotechsstarsweeklyforksweekly
jessestricker/zig-master.nixNix3000
plum-umd/QNPOpenQASMCoqOCaml1000
creaktive/stas-dotfilesPerlShell3010
pytorch/examplesPythonC++Shell20.9k09.3k0
guardian/apps-rendering-api-modelsThriftScalaShell0000
nadi555/TernodeShellMakefile200400
nodenv/nodenvShellCOther2k01750
mcaceresb/stata-honestdidStataRC490170
m1guelpf/auto-commitRustShell1.1k0370
hermitcore/rusty-hermitRustShell1.4k0760