From f615dbb5d2801a22a7a42821dc9a2825eb49d98e Mon Sep 17 00:00:00 2001 From: "Jonathan D.A. Jewell" <6759885+hyperpolymath@users.noreply.github.com> Date: Tue, 21 Jul 2026 06:23:13 +0100 Subject: [PATCH] chore(governance): add flake.nix for standards#505 gates --- flake.nix | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 flake.nix diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..239554b --- /dev/null +++ b/flake.nix @@ -0,0 +1,34 @@ +# SPDX-License-Identifier: MPL-2.0 +# SPDX-FileCopyrightText: 2026 Jonathan D.A. Jewell +# +# Development environment for affinescript. +# +# Estate policy is Guix primary / Nix fallback (hyperpolymath/standards). +# This is the Nix fallback tier. It is a dev shell, not a package build: +# it declares the toolchain needed to work on this repo, pinned to an +# exact nixpkgs revision per the estate SHA-pinning rule. +# +# Packages mirror the build tooling actually present in this repo +# (just ocaml) — not a generic estate default. +# +# nix develop # enter the shell +# nix flake check # verify this file evaluates (run before committing) +{ + description = "affinescript development environment"; + + inputs.nixpkgs.url = "github:NixOS/nixpkgs/b134951a4c9f3c995fd7be05f3243f8ecd65d798"; + + outputs = { self, nixpkgs }: + let + systems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forAllSystems = f: + nixpkgs.lib.genAttrs systems (system: f nixpkgs.legacyPackages.${system}); + in + { + devShells = forAllSystems (pkgs: { + default = pkgs.mkShell { + packages = with pkgs; [ just ocaml dune_3 ]; + }; + }); + }; +}