From 2605fbf6686c998b7746a4b729ce20466bc0e123 Mon Sep 17 00:00:00 2001 From: Peder Bergebakken Sundt Date: Wed, 22 Nov 2023 22:16:45 +0100 Subject: [PATCH] initial commit --- .envrc | 1 + .gitignore | 2 ++ flake.lock | 25 +++++++++++++++++++++++++ flake.nix | 29 +++++++++++++++++++++++++++++ 4 files changed, 57 insertions(+) create mode 100644 .envrc create mode 100644 .gitignore create mode 100644 flake.lock create mode 100644 flake.nix diff --git a/.envrc b/.envrc new file mode 100644 index 0000000..3550a30 --- /dev/null +++ b/.envrc @@ -0,0 +1 @@ +use flake diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..8228ec6 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +.remote.toml +.direnv/ diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..7f4e5e1 --- /dev/null +++ b/flake.lock @@ -0,0 +1,25 @@ +{ + "nodes": { + "nixpkgs": { + "locked": { + "lastModified": 1696419054, + "narHash": "sha256-EdR+dIKCfqL3voZUDYwcvgRDOektQB9KbhBVcE0/3Mo=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "7131f3c223a2d799568e4b278380cd9dac2b8579", + "type": "github" + }, + "original": { + "id": "nixpkgs", + "type": "indirect" + } + }, + "root": { + "inputs": { + "nixpkgs": "nixpkgs" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..bd21746 --- /dev/null +++ b/flake.nix @@ -0,0 +1,29 @@ +{ + outputs = { + self, + nixpkgs, + ... + } @ inputs: + let + forSystems = systems: f: nixpkgs.lib.genAttrs systems (system: f rec { + inherit system; + pkgs = nixpkgs.legacyPackages.${system}; + lib = nixpkgs.legacyPackages.${system}.lib; + }); + forAllSystems = forSystems [ + "x86_64-linux" + "aarch64-linux" + ]; + in { + devShells = forAllSystems ({ pkgs, ...}: { + default = pkgs.mkShell { + packages = with pkgs; [ + remote-exec + (python3.withPackages (ps: with ps; [ + typer + ])) + ]; + }; + }); + }; +}