dotfiles/flake.nix

81 lines
2.4 KiB
Nix
Raw Normal View History

2022-12-25 09:55:30 +00:00
{
2023-01-15 09:54:40 +00:00
nixConfig = {
2023-01-19 15:28:54 +00:00
accept-flake-config = true;
experimental-features = "nix-command flakes";
max-jobs = 12;
2023-01-15 09:54:40 +00:00
};
2022-12-25 09:55:30 +00:00
description = "My personal configuration in Nix (and some native configurations)";
inputs = {
2023-05-02 16:28:34 +00:00
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
nixpkgs-latest.url = "github:nixos/nixpkgs";
2023-06-18 09:51:33 +00:00
# deploy-rs.url = "github:serokell/deploy-rs";
2023-06-23 03:52:40 +00:00
std = {
url = "github:divnix/std";
inputs.devshell.url = "github:numtide/devshell";
};
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
neovim-nightly-overlay = {
# need to pin this until darwin build is successful again.
url = "github:nix-community/neovim-nightly-overlay?rev=88a6c749a7d126c49f3374f9f28ca452ea9419b8";
2023-06-22 17:34:20 +00:00
# url = "github:nix-community/neovim-nightly-overlay";
inputs.nixpkgs.follows = "nixpkgs";
};
nix-boost = {
url = "git+https://git.pegasust.com/pegasust/nix-boost?ref=bleed";
};
kpcli-py = {
url = "github:rebkwok/kpcli";
flake = false;
};
nix-index-database = {
url = "github:mic92/nix-index-database";
# Should show the latest nixpkgs whenever possible
inputs.nixpkgs.follows = "nixpkgs-latest";
};
2023-06-20 21:10:00 +00:00
sg-nvim = {
2023-06-22 17:34:20 +00:00
url = "git+https://github.com/pegasust/sg.nvim?ref=sg-cody-discover";
2023-06-20 21:10:00 +00:00
};
2022-12-25 09:55:30 +00:00
};
2023-06-18 09:51:33 +00:00
outputs = {
self,
std,
...
} @ inputs:
2023-06-18 00:46:31 +00:00
std.growOn
2023-05-02 16:28:34 +00:00
{
# boilerplate
inherit inputs;
2023-06-20 21:10:00 +00:00
# All cell blocks are under ./nix/<cell>/<cellblock> as `<cellblock>.nix`
2023-05-02 16:28:34 +00:00
# or `<cellblock/default.nix`
2023-06-20 21:10:00 +00:00
cellsFrom = ./nix;
# modules = ./nix/modules;
2023-05-02 16:28:34 +00:00
2023-06-18 00:46:31 +00:00
cellBlocks = let
inherit (std.blockTypes) devshells functions anything installables;
2023-06-18 00:46:31 +00:00
in [
(devshells "devshells")
(devshells "userShells")
(functions "home-profiles")
(functions "home-modules")
2023-06-18 09:51:33 +00:00
(anything "home-configs")
(installables "packages")
(anything "lib")
2023-06-18 00:46:31 +00:00
];
2023-05-02 16:28:34 +00:00
}
2023-01-12 18:42:20 +00:00
{
devShells = std.harvest self [["dotfiles" "devshells"]];
homeModules = std.pick self [["repo" "home-modules"]];
packages = std.harvest self [["repo" "packages"]];
legacyPackages = std.harvest self [["repo" "home-configs"]];
lib = std.pick self [["repo" "lib"]];
2023-06-18 00:46:31 +00:00
# TODO: Debug only
homeProfiles = std.pick self [["repo" "home-profiles"]];
};
2022-12-25 09:55:30 +00:00
}