mirror of
https://github.com/LnL7/nix-darwin.git
synced 2024-12-14 11:57:34 +00:00
separate module eval and move example configuration
This commit is contained in:
parent
033499c0ed
commit
f8df0090b6
2 changed files with 38 additions and 29 deletions
25
default.nix
Normal file
25
default.nix
Normal file
|
@ -0,0 +1,25 @@
|
|||
{ pkgs ? import <nixpkgs> {}, config ? <darwin-config> }:
|
||||
|
||||
let
|
||||
|
||||
eval = pkgs.lib.evalModules {
|
||||
check = true;
|
||||
args = { inherit pkgs; };
|
||||
modules =
|
||||
[ config
|
||||
./modules/system
|
||||
./modules/system/activation-scripts.nix
|
||||
./modules/system/defaults
|
||||
./modules/system/etc.nix
|
||||
./modules/system/launchd.nix
|
||||
./modules/environment
|
||||
./modules/launchd
|
||||
./modules/services/activate-system.nix
|
||||
./modules/services/nix-daemon.nix
|
||||
./modules/programs/tmux.nix
|
||||
./modules/programs/nix-darwin.nix
|
||||
];
|
||||
};
|
||||
|
||||
in
|
||||
eval
|
|
@ -2,24 +2,6 @@
|
|||
|
||||
let
|
||||
|
||||
eval = pkgs.lib.evalModules
|
||||
{ check = true;
|
||||
args = { pkgs = import <nixpkgs> {}; };
|
||||
modules =
|
||||
[ config
|
||||
./modules/system
|
||||
./modules/system/activation-scripts.nix
|
||||
./modules/system/defaults
|
||||
./modules/system/etc.nix
|
||||
./modules/system/launchd.nix
|
||||
./modules/environment
|
||||
./modules/launchd
|
||||
./modules/services/activate-system.nix
|
||||
./modules/services/nix-daemon.nix
|
||||
./modules/programs/tmux.nix
|
||||
];
|
||||
};
|
||||
|
||||
config =
|
||||
{ config, lib, pkgs, ... }:
|
||||
{
|
||||
|
@ -179,14 +161,15 @@ let
|
|||
'';
|
||||
};
|
||||
|
||||
eval = import ../.. { inherit config; };
|
||||
|
||||
in {
|
||||
inherit eval;
|
||||
in
|
||||
|
||||
allowUnfree = true;
|
||||
{
|
||||
inherit (eval) config;
|
||||
inherit (eval.config.system) build;
|
||||
|
||||
packageOverrides = self: {
|
||||
|
||||
nixdarwin = eval.config.system.build;
|
||||
|
||||
lnl.zsh = pkgs.runCommand pkgs.zsh.name
|
||||
|
@ -243,16 +226,17 @@ in {
|
|||
|
||||
source $HOME/.vimrc.local
|
||||
'';
|
||||
vimrcConfig.vam.knownPlugins = with pkgs.vimUtils; (pkgs.vimPlugins // {
|
||||
vim-nix = buildVimPluginFrom2Nix {
|
||||
name = "vim-nix-unstable";
|
||||
src = ../vim-nix;
|
||||
};
|
||||
});
|
||||
# vimrcConfig.vam.knownPlugins = with pkgs.vimUtils; (pkgs.vimPlugins // {
|
||||
# vim-nix = buildVimPluginFrom2Nix {
|
||||
# name = "vim-nix-unstable";
|
||||
# src = ../../../vim-nix;
|
||||
# };
|
||||
# });
|
||||
vimrcConfig.vam.pluginDictionaries = [
|
||||
{ names = [ "fzfWrapper" "youcompleteme" "fugitive" "surround" "vim-nix" "colors-solarized" ]; }
|
||||
];
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
allowUnfree = true;
|
||||
}
|
Loading…
Reference in a new issue