diff --git a/flake.lock b/flake.lock index dbbdc635..85989311 100644 --- a/flake.lock +++ b/flake.lock @@ -1,5 +1,21 @@ { "nodes": { + "crane": { + "flake": false, + "locked": { + "lastModified": 1661875961, + "narHash": "sha256-f1h/2c6Teeu1ofAHWzrS8TwBPcnN+EEu+z1sRVmMQTk=", + "owner": "ipetkov", + "repo": "crane", + "rev": "d9f394e4e20e97c2a60c3ad82c2b6ef99be19e24", + "type": "github" + }, + "original": { + "owner": "ipetkov", + "repo": "crane", + "type": "github" + } + }, "darwin": { "inputs": { "nixpkgs": [ @@ -21,6 +37,82 @@ "type": "github" } }, + "devshell": { + "flake": false, + "locked": { + "lastModified": 1667210711, + "narHash": "sha256-IoErjXZAkzYWHEpQqwu/DeRNJGFdR7X2OGbkhMqMrpw=", + "owner": "numtide", + "repo": "devshell", + "rev": "96a9dd12b8a447840cc246e17a47b81a4268bba7", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "devshell", + "type": "github" + } + }, + "dream2nix": { + "inputs": { + "alejandra": [ + "helix", + "nci" + ], + "all-cabal-json": [ + "helix", + "nci" + ], + "crane": "crane", + "devshell": [ + "helix", + "nci", + "devshell" + ], + "flake-utils-pre-commit": [ + "helix", + "nci" + ], + "ghc-utils": [ + "helix", + "nci" + ], + "gomod2nix": [ + "helix", + "nci" + ], + "mach-nix": [ + "helix", + "nci" + ], + "nixpkgs": [ + "helix", + "nci", + "nixpkgs" + ], + "poetry2nix": [ + "helix", + "nci" + ], + "pre-commit-hooks": [ + "helix", + "nci" + ] + }, + "locked": { + "lastModified": 1668851003, + "narHash": "sha256-X7RCQQynbxStZR2m7HW38r/msMQwVl3afD6UXOCtvx4=", + "owner": "nix-community", + "repo": "dream2nix", + "rev": "c77e8379d8fe01213ba072e40946cbfb7b58e628", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "dream2nix", + "type": "github" + } + }, "flake-compat": { "flake": false, "locked": { @@ -53,6 +145,44 @@ "type": "github" } }, + "flake-utils_2": { + "locked": { + "lastModified": 1659877975, + "narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "c0e246b9b83f637f4681389ecabcb2681b4f3af0", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "helix": { + "inputs": { + "nci": "nci", + "nixpkgs": [ + "nixpkgs-nixos-unstable" + ], + "rust-overlay": "rust-overlay" + }, + "locked": { + "lastModified": 1670381690, + "narHash": "sha256-0VPEA2XixJ+5NGS0zcnntcDWDByUQD4EFuoSSE+Q7yk=", + "owner": "helix-editor", + "repo": "helix", + "rev": "96ff64a84a4948b0aa85a453276cb0091fb9c792", + "type": "github" + }, + "original": { + "owner": "helix-editor", + "ref": "22.12", + "repo": "helix", + "type": "github" + } + }, "home-manager": { "inputs": { "nixpkgs": [ @@ -75,6 +205,33 @@ "type": "github" } }, + "nci": { + "inputs": { + "devshell": "devshell", + "dream2nix": "dream2nix", + "nixpkgs": [ + "helix", + "nixpkgs" + ], + "rust-overlay": [ + "helix", + "rust-overlay" + ] + }, + "locked": { + "lastModified": 1669011203, + "narHash": "sha256-Lymj4HktNEFmVXtwI0Os7srDXHZbZW0Nzw3/+5Hf8ko=", + "owner": "yusdacra", + "repo": "nix-cargo-integration", + "rev": "c5133b91fc1d549087c91228bd213f2518728a4b", + "type": "github" + }, + "original": { + "owner": "yusdacra", + "repo": "nix-cargo-integration", + "type": "github" + } + }, "nil": { "inputs": { "flake-utils": [ @@ -83,7 +240,7 @@ "nixpkgs": [ "nixpkgs-nixos-unstable" ], - "rust-overlay": "rust-overlay" + "rust-overlay": "rust-overlay_2" }, "locked": { "lastModified": 1669929738, @@ -201,6 +358,7 @@ "darwin": "darwin", "flake-compat": "flake-compat", "flake-utils": "flake-utils", + "helix": "helix", "home-manager": "home-manager", "nil": "nil", "nixos-hardware": "nixos-hardware", @@ -212,6 +370,28 @@ } }, "rust-overlay": { + "inputs": { + "flake-utils": "flake-utils_2", + "nixpkgs": [ + "helix", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1668998422, + "narHash": "sha256-G/BklIplCHZEeDIabaaxqgITdIXtMolRGlwxn9jG2/Q=", + "owner": "oxalica", + "repo": "rust-overlay", + "rev": "68ab029c93f8f8eed4cf3ce9a89a9fd4504b2d6e", + "type": "github" + }, + "original": { + "owner": "oxalica", + "repo": "rust-overlay", + "type": "github" + } + }, + "rust-overlay_2": { "inputs": { "flake-utils": [ "nil", diff --git a/flake.nix b/flake.nix index 239cfc42..0cb87e02 100644 --- a/flake.nix +++ b/flake.nix @@ -2,7 +2,7 @@ description = "NixOS configuration with flakes"; outputs = { self, flake-utils, flake-compat, home-manager , nixpkgs-nixos-unstable, nixpkgs-master, nixpkgs-stable, darwin - , nixos-hardware, nur, sops, nil }@inputs: + , nixos-hardware, nur, sops, nil, helix }@inputs: let mkServer = pkgs: system: hostname: @@ -247,6 +247,13 @@ inputs.flake-utils.follows = "flake-utils"; }; + helix = { + type = "github"; + owner = "helix-editor"; + repo = "helix"; + ref = "22.12"; + inputs.nixpkgs.follows = "nixpkgs-nixos-unstable"; + }; sops = { type = "github"; owner = "Mic92"; diff --git a/nixos/home-manager/default.nix b/nixos/home-manager/default.nix index b97f1ce1..cc37ad3c 100644 --- a/nixos/home-manager/default.nix +++ b/nixos/home-manager/default.nix @@ -23,6 +23,7 @@ in { ./programs.nix ./programs/emacs/home.nix + ./programs/helix.nix ./programs/newsboat.nix ./programs/ssh.nix ./programs/tmux.nix diff --git a/nixos/home-manager/programs/helix.nix b/nixos/home-manager/programs/helix.nix new file mode 100644 index 00000000..3a19c948 --- /dev/null +++ b/nixos/home-manager/programs/helix.nix @@ -0,0 +1,6 @@ +{ config, pkgs, lib, inputs, system, ... }: { + programs.helix = { + enable = true; + package = inputs.helix.packages."${system}".helix; + }; +}