Compare commits
4 Commits
0350f74f7b
...
2540156e17
Author | SHA1 | Date |
---|---|---|
Zynh Ludwig | 2540156e17 | |
Zynh Ludwig | 08f8c71880 | |
Zynh Ludwig | 78119f6aad | |
Zynh Ludwig | 4d13192751 |
|
@ -1,24 +1,19 @@
|
||||||
{ pkgs, lib, config, ... }:
|
{ pkgs, lib, config, inputs, ... }:
|
||||||
|
|
||||||
let
|
let
|
||||||
cfg = config.snowhawk.neovim;
|
cfg = config.snowhawk.neovim;
|
||||||
|
|
||||||
|
nightlyPackage = inputs.neovim-overlay.packages.${pkgs.system}.default;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options.snowhawk.neovim = {
|
options.snowhawk.neovim = {
|
||||||
enable = lib.mkEnableOption "neovim";
|
enable = lib.mkEnableOption "neovim home-manager module";
|
||||||
|
|
||||||
|
nightly = lib.mkEnableOption "nightly build of neovim";
|
||||||
|
|
||||||
package = lib.mkPackageOption pkgs "neovim" {
|
package = lib.mkPackageOption pkgs "neovim" {
|
||||||
default = [ "neovim-unwrapped" ];
|
default = [ "neovim-unwrapped" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
# This should be close to identical to above
|
|
||||||
#
|
|
||||||
# package = lib.mkOption {
|
|
||||||
# type = lib.types.package;
|
|
||||||
# default = pkgs.neovim-unwrapped;
|
|
||||||
# defaultText = lib.literalExpression "pkgs.neovim-unwrapped";
|
|
||||||
# description = "The package to use for the neovim binary.";
|
|
||||||
# };
|
|
||||||
};
|
};
|
||||||
config =
|
config =
|
||||||
let
|
let
|
||||||
|
@ -31,6 +26,8 @@ in
|
||||||
};
|
};
|
||||||
in
|
in
|
||||||
lib.mkIf cfg.enable {
|
lib.mkIf cfg.enable {
|
||||||
|
snowhawk.neovim.package = lib.mkIf cfg.nightly (lib.mkDefault nightlyPackage);
|
||||||
|
|
||||||
# Set nvim as manpager and default editor
|
# Set nvim as manpager and default editor
|
||||||
home.sessionVariables = {
|
home.sessionVariables = {
|
||||||
EDITOR = "nvim";
|
EDITOR = "nvim";
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ pkgs, inputs, lib, ... }:
|
{ pkgs, lib, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
|
@ -14,10 +14,7 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
homeNetwork = true;
|
homeNetwork = true;
|
||||||
};
|
};
|
||||||
neovim = {
|
neovim.enable = true;
|
||||||
enable = true;
|
|
||||||
package = inputs.neovim-overlay.packages.${pkgs.system}.default;
|
|
||||||
};
|
|
||||||
sops.enable = true;
|
sops.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue