From 119a8a48de5b9ab9c366a89d0875d04ef5aa92d5 Mon Sep 17 00:00:00 2001 From: actias Date: Sun, 19 May 2024 19:00:53 +0100 Subject: [PATCH] added nix flake --- flake.lock | 90 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ flake.nix | 24 +++++++++++++++ 2 files changed, 114 insertions(+) create mode 100644 flake.lock create mode 100644 flake.nix diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..03e56bf --- /dev/null +++ b/flake.lock @@ -0,0 +1,90 @@ +{ + "nodes": { + "flake-parts": { + "inputs": { + "nixpkgs-lib": "nixpkgs-lib" + }, + "locked": { + "lastModified": 1715865404, + "narHash": "sha256-/GJvTdTpuDjNn84j82cU6bXztE0MSkdnTWClUCRub78=", + "owner": "hercules-ci", + "repo": "flake-parts", + "rev": "8dc45382d5206bd292f9c2768b8058a8fd8311d9", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "flake-parts", + "type": "github" + } + }, + "nix-npm-buildpackage": { + "inputs": { + "nixpkgs": "nixpkgs" + }, + "locked": { + "lastModified": 1686315622, + "narHash": "sha256-ccqZqY6wUFot0ewyNKQUrMR6IEliGza+pjKoSVMXIeM=", + "owner": "serokell", + "repo": "nix-npm-buildpackage", + "rev": "991a792bccd611842f6bc1aa99fe80380ad68d44", + "type": "github" + }, + "original": { + "owner": "serokell", + "repo": "nix-npm-buildpackage", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1653917367, + "narHash": "sha256-04MsJC0g9kE01nBuXThMppZK+yvCZECQnUaZKSU+HJo=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "437c8e6554911095f0557d524e9d2ffe1c26e33a", + "type": "github" + }, + "original": { + "id": "nixpkgs", + "type": "indirect" + } + }, + "nixpkgs-lib": { + "locked": { + "lastModified": 1714640452, + "narHash": "sha256-QBx10+k6JWz6u7VsohfSw8g8hjdBZEf8CFzXH1/1Z94=", + "type": "tarball", + "url": "https://github.com/NixOS/nixpkgs/archive/50eb7ecf4cd0a5756d7275c8ba36790e5bd53e33.tar.gz" + }, + "original": { + "type": "tarball", + "url": "https://github.com/NixOS/nixpkgs/archive/50eb7ecf4cd0a5756d7275c8ba36790e5bd53e33.tar.gz" + } + }, + "nixpkgs_2": { + "locked": { + "lastModified": 1715996989, + "narHash": "sha256-ObD9YSelkwCAylEXJHcNjrn3hLOfIVScB1tPz9zeDN8=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "63d3e5d82edf5a138e7d0872231cc23ed4e740fd", + "type": "github" + }, + "original": { + "id": "nixpkgs", + "ref": "nixpkgs-unstable", + "type": "indirect" + } + }, + "root": { + "inputs": { + "flake-parts": "flake-parts", + "nix-npm-buildpackage": "nix-npm-buildpackage", + "nixpkgs": "nixpkgs_2" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..588ed92 --- /dev/null +++ b/flake.nix @@ -0,0 +1,24 @@ +{ + description = "A flake for terminal-wallet-cli"; + + inputs = { + nixpkgs.url = "nixpkgs/nixpkgs-unstable"; + flake-parts.url = "github:hercules-ci/flake-parts"; + nix-npm-buildpackage.url = "github:serokell/nix-npm-buildpackage"; + }; + + outputs = inputs @ {...}: + inputs.flake-parts.lib.mkFlake {inherit inputs;} { + systems = ["x86_64-linux" "aarch64-linux" "aarch64-darwin" "x86_64-darwin"]; + perSystem = {pkgs, ...}: { + devShells.default = pkgs.mkShell { + buildInputs = with pkgs; [ + nodejs-18_x + typescript + nodePackages.eslint + nodePackages.rimraf + ]; + }; + }; + }; +}