helm/default.nix

42 lines
1.3 KiB
Nix
Raw Normal View History

2020-01-17 01:22:50 -08:00
# default.nix --- my dotfile bootstrapper
2019-08-06 10:56:54 -07:00
2020-01-12 15:17:17 -08:00
device:
{ pkgs, options, lib, config, ... }:
2019-08-06 10:56:54 -07:00
{
networking.hostName = lib.mkDefault device;
2020-01-12 15:28:02 -08:00
2019-08-06 10:56:54 -07:00
imports = [
2020-03-28 22:48:43 -07:00
./modules
2020-01-17 01:22:50 -08:00
"${./hosts}/${device}"
2019-08-06 10:56:54 -07:00
];
2020-01-17 01:22:50 -08:00
### NixOS
nix.autoOptimiseStore = true;
nix.nixPath = options.nix.nixPath.default ++ [
# So we can use absolute import paths
2020-02-01 18:05:55 -08:00
"bin=/etc/dotfiles/bin"
2020-01-17 01:22:50 -08:00
"config=/etc/dotfiles/config"
];
2020-03-28 22:48:43 -07:00
# Add custom packages & unstable channel, so they can be accessed via pkgs.*
2020-01-17 01:22:50 -08:00
nixpkgs.overlays = import ./overlays.nix;
nixpkgs.config.allowUnfree = true; # forgive me Stallman senpai
2020-03-28 22:48:43 -07:00
environment.systemPackages = with pkgs; [
gnumake # for our own makefile
my.cached-nix-shell # for instant nix-shell scripts
];
environment.shellAliases = {
nix-env = "NIXPKGS_ALLOW_UNFREE=1 nix-env";
nix-shell = ''NIX_PATH="nixpkgs-overlays=/etc/dotfiles/overlays.nix:$NIX_PATH" nix-shell'';
nsh = "nix-shell";
nen = "nix-env";
dots = "make -C ~/.dotfiles";
};
2019-08-06 10:56:54 -07:00
# This value determines the NixOS release with which your system is to be
# compatible, in order to avoid breaking some software such as database
# servers. You should change this only after NixOS release notes say you
# should.
2019-10-17 16:57:00 -07:00
system.stateVersion = "19.09"; # Did you read the comment?
2019-08-06 10:56:54 -07:00
}