Satellite dev module (+ other changes probably, including eww install)
This commit is contained in:
parent
5e696cf9d0
commit
da817da3b9
10 changed files with 42 additions and 15 deletions
modules/home-manager
|
@ -5,4 +5,5 @@
|
|||
discord = import ./discord.nix;
|
||||
fonts = import ./fonts.nix;
|
||||
firefox = import ./firefox;
|
||||
satellite-dev = import ./satellite-dev.nix;
|
||||
}
|
||||
|
|
25
modules/home-manager/satellite-dev.nix
Normal file
25
modules/home-manager/satellite-dev.nix
Normal file
|
@ -0,0 +1,25 @@
|
|||
{ lib, config, ... }: {
|
||||
options.satellite-dev = {
|
||||
enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
description = "While true, makes out of store symlinks for files in dev mode";
|
||||
};
|
||||
|
||||
root = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "~/Projects/satellite";
|
||||
description = "Where the satellite repo is cloned";
|
||||
};
|
||||
|
||||
path = lib.mkOption {
|
||||
type = lib.types.functionTo lib.types.path;
|
||||
description = "The function used to conditionally symlink in or out of store based on the above paths";
|
||||
};
|
||||
};
|
||||
|
||||
config.satellite-dev.path = path:
|
||||
if config.satellite-dev.enable then
|
||||
config.lib.file.mkOutOfStoreSymlink "${config.satellite-dev.root}/${path}"
|
||||
else "${../..}/${path}";
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue