From b38eb47b44a243af39ef85e3add8a0969fd0ed59 Mon Sep 17 00:00:00 2001 From: Daylin Morgan Date: Thu, 25 Jan 2024 16:20:40 -0600 Subject: [PATCH] add nix flake and nimble file --- flake.lock | 27 +++++++++++++++++++++++++++ flake.nix | 32 ++++++++++++++++++++++++++++++++ hyprman.nimble | 13 +++++++++++++ 3 files changed, 72 insertions(+) create mode 100644 flake.lock create mode 100644 flake.nix create mode 100644 hyprman.nimble diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..9fd8a3e --- /dev/null +++ b/flake.lock @@ -0,0 +1,27 @@ +{ + "nodes": { + "nixpkgs": { + "locked": { + "lastModified": 1706006310, + "narHash": "sha256-nDPz0fj0IFcDhSTlXBU2aixcnGs2Jm4Zcuoj0QtmiXQ=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "b43bb235efeab5324c5e486882ef46749188eee2", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixpkgs-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "nixpkgs": "nixpkgs" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..3d0a63a --- /dev/null +++ b/flake.nix @@ -0,0 +1,32 @@ +{ + description = "nix + cosmograph"; + inputs = { + nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable"; + }; + + outputs = inputs @ { + self, + nixpkgs, + }: let + inherit (nixpkgs.lib) genAttrs; + supportedSystems = ["x86_64-linux" "x86_64-darwin" "aarch64-linux" "aarch64-darwin"]; + forAllSystems = f: genAttrs supportedSystems (system: f nixpkgs.legacyPackages.${system}); + in { + devShells = forAllSystems (pkgs:{ + default = pkgs.mkShell { + buildInputs = with pkgs; [ + nim + nimble + ]; + };}); + packages = forAllSystems (pkgs: { + nixgraph = pkgs.buildNimPackage { + pname = "hyprman"; + version = "2023.1001"; + src =./.; + }; + default = self.packages.${pkgs.system}.nixgraph; + } + ); + }; +} diff --git a/hyprman.nimble b/hyprman.nimble new file mode 100644 index 0000000..9fa1135 --- /dev/null +++ b/hyprman.nimble @@ -0,0 +1,13 @@ +# Package + +version = "2023.1001" +author = "Daylin Morgan" +description = "hyprland utility" +license = "MIT" +srcDir = "src" +bin = @["hyprman"] + + +# Dependencies + +requires "nim >= 2.0.0"