From 02ccf8f35a2726e9360504d3c504652bd6fe736f Mon Sep 17 00:00:00 2001 From: Marty Sluijtman Date: Fri, 12 Jan 2024 14:47:55 +0100 Subject: [PATCH] Rename and default system support --- flake.lock | 61 ++++++++++++++++++++++ flake.nix | 11 +++- lib.nix | 3 -- nightmare.nix | 3 ++ {lib => nightmare}/getKittyColorscheme.nix | 0 5 files changed, 73 insertions(+), 5 deletions(-) create mode 100644 flake.lock delete mode 100644 lib.nix create mode 100644 nightmare.nix rename {lib => nightmare}/getKittyColorscheme.nix (100%) diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..c6c8262 --- /dev/null +++ b/flake.lock @@ -0,0 +1,61 @@ +{ + "nodes": { + "flake-utils": { + "inputs": { + "systems": "systems" + }, + "locked": { + "lastModified": 1701680307, + "narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "4022d587cbbfd70fe950c1e2083a02621806a725", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1704722960, + "narHash": "sha256-mKGJ3sPsT6//s+Knglai5YflJUF2DGj7Ai6Ynopz0kI=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "317484b1ead87b9c1b8ac5261a8d2dd748a0492d", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "flake-utils": "flake-utils", + "nixpkgs": "nixpkgs" + } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix index f6f197e..268cc28 100644 --- a/flake.nix +++ b/flake.nix @@ -1,5 +1,12 @@ { description = "A collection of tedious nix functions"; - outputs = _: { - lib = import ./lib.nix; + inputs = { + nixpkgs.url = github:NixOS/nixpkgs/nixos-unstable; + flake-utils.url = github:numtide/flake-utils; }; + outputs = { nixpkgs, flake-utils, self }: + flake-utils.lib.eachDefaultSystem (system: + let pkgs = import nixpkgs { inherit system; }; + in { + nightmare = pkgs.callPackage ./nightmare.nix {}; + }); } diff --git a/lib.nix b/lib.nix deleted file mode 100644 index 93e410e..0000000 --- a/lib.nix +++ /dev/null @@ -1,3 +0,0 @@ -{ - getKittyColorscheme = import ./lib/getKittyColorscheme.nix; -} diff --git a/nightmare.nix b/nightmare.nix new file mode 100644 index 0000000..5ed8910 --- /dev/null +++ b/nightmare.nix @@ -0,0 +1,3 @@ +{ pkgs, ... }: { + getKittyColorscheme = pkgs.callPackage ./nightmare/getKittyColorscheme.nix { }; +} diff --git a/lib/getKittyColorscheme.nix b/nightmare/getKittyColorscheme.nix similarity index 100% rename from lib/getKittyColorscheme.nix rename to nightmare/getKittyColorscheme.nix