All Projects → sheenobu → Nix Home

sheenobu / Nix Home

Licence: mit
Utilities for working with user configurations in Nix.

Programming Languages

shell
77523 projects

Projects that are alternatives of or similar to Nix Home

nixpkgs
My Nix system configs!
Stars: ✭ 143 (+33.64%)
Mutual labels:  dotfiles, nix
Nix Darwin
nix modules for darwin
Stars: ✭ 700 (+554.21%)
Mutual labels:  dotfiles, nix
nixcfg
NixOS and Home-Manager configurations for all of my devices (desktop, Pinebook Pro, RPi4, cloud servers, etc). Like dotfiles, but way better. (née 'nixos-config')
Stars: ✭ 119 (+11.21%)
Mutual labels:  dotfiles, nix
dotfiles
My NixOS dotfiles
Stars: ✭ 21 (-80.37%)
Mutual labels:  dotfiles, nix
Dotfiles
well-tailored NixOS & nix-darwin dotfiles
Stars: ✭ 63 (-41.12%)
Mutual labels:  dotfiles, nix
dotnix
Shackled within an elaborate prison of my own design.
Stars: ✭ 35 (-67.29%)
Mutual labels:  dotfiles, nix
Dotfiles
Zsh, Karabiner, VS Code, Sublime, Neovim, Nix
Stars: ✭ 634 (+492.52%)
Mutual labels:  dotfiles, nix
Shabka
Shabka. Declaritive description of my network, workstations and servers.
Stars: ✭ 138 (+28.97%)
Mutual labels:  dotfiles, nix
Idempotent Desktop
🛸 NixOS, Xmonad, Neovim
Stars: ✭ 51 (-52.34%)
Mutual labels:  dotfiles, nix
Nix Dotfiles
My personal nix and nixos configuration
Stars: ✭ 48 (-55.14%)
Mutual labels:  dotfiles, nix
Home Manager
Manage a user environment using Nix [maintainer=@rycee]
Stars: ✭ 2,447 (+2186.92%)
Mutual labels:  dotfiles, nix
Bauer
An Emacs+Nix IDE
Stars: ✭ 89 (-16.82%)
Mutual labels:  dotfiles, nix
Dotfiles
My dotfiles
Stars: ✭ 150 (+40.19%)
Mutual labels:  dotfiles, nix
system
Declarative NixOS system configuration for all my machines
Stars: ✭ 14 (-86.92%)
Mutual labels:  dotfiles, nix
Dotfiles
~ 🍭 ~
Stars: ✭ 147 (+37.38%)
Mutual labels:  dotfiles, nix
Dotfiles
And I say hey, what's going on?
Stars: ✭ 348 (+225.23%)
Mutual labels:  dotfiles, nix
Nix Config
My NixOS configuration
Stars: ✭ 112 (+4.67%)
Mutual labels:  dotfiles, nix
Dotfiles
Configuration files for XMonad, Emacs, NixOS, Taffybar and more.
Stars: ✭ 127 (+18.69%)
Mutual labels:  dotfiles, nix
Nixos Config
NixOS configurations for server and desktop systems, including user specific config. with Home Manager
Stars: ✭ 30 (-71.96%)
Mutual labels:  dotfiles, nix
Homies
linux package management
Stars: ✭ 86 (-19.63%)
Mutual labels:  dotfiles, nix

nix-home

Utilities for working with user configurations in Nix.

commands

nix-home

The command delegates to nix-env, so it supports any parameter that nix-env does.

Running nix-home by itself builds and symlinks the files defined in $HOME/default.nix

NOTE: nix-home --dry-run will still attempt to link. This is a bug! #15

nix-build-home

nix-build-home builds $HOME/default.nix via nix-build and prints out the derivation. Useful for testing your config without linking to your home directory. Does NOT generate a ./result symlink.

Installation

The package for installing nix-home is on the wiki here. Include it in your configuration.nix file via:

environment.systemPackages = [
  ((pkgs.callPackage path/to/nixhome/package.nix) { })
]

Supported

nix-home, when invoked, builds ~/default.nix, which must define a derivation.

nix-home calls nix-env to build a profile from the derivation. The derivation is an overlay that gets linked into your home directory.

There is a helper function in nixhome called mkHome, for making the derivation:

with import <nixpkgs> {};
with import <nixhome> { inherit stdenv; inherit pkgs; };
mkHome {
  user = "username";
  files = {
	 ".screenrc" = ./path-to-file;
	 ".vimrc" = "${somePkg}/path-to-file";
	 ".bashrc".content = ''
		... bashrc conents
	 '';
  };
}

Generations

Generations are supported via standard nix-env parameters:

* nix-home --list-generations
* nix-home --rollback
* nix-home --switch-generation 1
* nix-home --delete-generations 1 2 3
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].