From aecd6f2395676f9414d839bcd0fa31f1d125ab5e Mon Sep 17 00:00:00 2001 From: hyperpolymath <6759885+hyperpolymath@users.noreply.github.com> Date: Mon, 22 Jun 2026 21:22:09 +0100 Subject: [PATCH] chore: purge banned package managers (Nix) + dependabot accuracy MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Nix is banned estate-wide (Guix only). Removes: - flake.nix (the flake itself) - .envrc nix-flake activation block - Justfile nix-shell recipe - install-tools.sh nix branch (now guix-first, then asdf) - .gitattributes *.nix / flake.lock rules - .gitignore Nix/flake.lock section - .editorconfig [*.nix] block Dependabot: trim to github-actions only. The repo ships no language manifests (no Cargo.toml/mix.exs/etc.), and nix/pip(Python)/npm ecosystems are all banned estate-wide; this also drops the cargo ignore:semver-patch anti-pattern that came with the template. Not included (left for manual/owner passes): Nix mentions in .github/CONTRIBUTING.md (broken template residue — needs dedup decision), docs that describe Nix as an external/standard option, and .machine_readable references (part of the separate machine-readable restructure). Co-Authored-By: Claude Opus 4.8 (1M context) --- .editorconfig | 3 - .envrc | 5 - .gitattributes | 2 - .github/dependabot.yml | 36 +--- .gitignore | 6 - .../scripts/lifecycle/install-tools.sh | 10 +- Justfile | 4 - flake.nix | 170 ------------------ 8 files changed, 7 insertions(+), 229 deletions(-) delete mode 100644 flake.nix diff --git a/.editorconfig b/.editorconfig index bcdbb4d..a50e917 100644 --- a/.editorconfig +++ b/.editorconfig @@ -56,9 +56,6 @@ indent_size = 2 [*.scm] indent_size = 2 -[*.nix] -indent_size = 2 - [Justfile] indent_style = space indent_size = 4 diff --git a/.envrc b/.envrc index 64462ca..1b9e935 100644 --- a/.envrc +++ b/.envrc @@ -12,11 +12,6 @@ if has guix && [ -f guix.scm ]; then use guix fi -# Load Nix flake if flake.nix exists -if has nix && [ -f flake.nix ]; then - use flake -fi - # Project environment variables export PROJECT_NAME="a2ml-validate-action" export RSR_TIER="infrastructure" diff --git a/.gitattributes b/.gitattributes index c95d5eb..0a9c6ef 100644 --- a/.gitattributes +++ b/.gitattributes @@ -18,7 +18,6 @@ *.scm text eol=lf *.a2ml text eol=lf linguist-language=TOML *.ncl text eol=lf -*.nix text eol=lf # Docs *.md text eol=lf diff=markdown @@ -52,4 +51,3 @@ Containerfile text eol=lf # Lock files Cargo.lock text eol=lf -diff -flake.lock text eol=lf -diff diff --git a/.github/dependabot.yml b/.github/dependabot.yml index d5cd4e9..ff83f93 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,6 +1,7 @@ # SPDX-License-Identifier: MPL-2.0 # Dependabot configuration for RSR-compliant repositories -# Covers common ecosystems - remove unused ones for your project +# Only github-actions is enabled: this repo ships no language manifests +# (no Cargo.toml/mix.exs/etc.), and Nix/Python(pip)/npm are banned estate-wide. version: 2 updates: @@ -13,36 +14,3 @@ updates: actions: patterns: - "*" - - # Rust/Cargo - - package-ecosystem: "cargo" - directory: "/" - schedule: - interval: "weekly" - ignore: - - dependency-name: "*" - update-types: ["version-update:semver-patch"] - - # Elixir/Mix - - package-ecosystem: "mix" - directory: "/" - schedule: - interval: "weekly" - - # Node.js/npm - - package-ecosystem: "npm" - directory: "/" - schedule: - interval: "weekly" - - # Python/pip - - package-ecosystem: "pip" - directory: "/" - schedule: - interval: "weekly" - - # Nix flakes - - package-ecosystem: "nix" - directory: "/" - schedule: - interval: "weekly" diff --git a/.gitignore b/.gitignore index 037efd3..7c5d7a5 100644 --- a/.gitignore +++ b/.gitignore @@ -52,12 +52,6 @@ __pycache__/ /obj/ /bin/ -# Nix -# flake.lock is ignored in the template repo because each project should -# generate its own lock file on first use. In derived projects, REMOVE this -# line and track flake.lock for reproducible builds. -flake.lock - # Haskell /.stack-work/ /dist-newstyle/ diff --git a/.machine_readable/scripts/lifecycle/install-tools.sh b/.machine_readable/scripts/lifecycle/install-tools.sh index 408df64..71cff06 100755 --- a/.machine_readable/scripts/lifecycle/install-tools.sh +++ b/.machine_readable/scripts/lifecycle/install-tools.sh @@ -3,15 +3,15 @@ # # install-tools.sh — Developer toolchain installer # -# Detects and installs the required project toolchain (asdf, nix, or guix). +# Detects and installs the required project toolchain (guix or asdf). set -euo pipefail echo "=== RSR Toolchain Installer ===" -if [ -f "flake.nix" ] && command -v nix &>/dev/null; then - echo "Nix detected. Setting up development shell..." - nix develop --command echo "Nix shell verified." +if [ -f "guix.scm" ] && command -v guix &>/dev/null; then + echo "Guix detected. Setting up development environment..." + guix shell -D -f guix.scm -- echo "Guix environment verified." elif [ -f ".tool-versions" ] && command -v asdf &>/dev/null; then echo "asdf detected. Installing plugins and tools..." while read -r line; do @@ -20,7 +20,7 @@ elif [ -f ".tool-versions" ] && command -v asdf &>/dev/null; then done < .tool-versions asdf install else - echo "No standard toolchain (Nix/asdf) detected or installed." + echo "No standard toolchain (guix/asdf) detected or installed." echo "Please refer to README.adoc for manual setup instructions." fi diff --git a/Justfile b/Justfile index 8cf9d85..ecc6238 100644 --- a/Justfile +++ b/Justfile @@ -800,10 +800,6 @@ guix-shell: guix-build: guix build -f guix.scm -# Enter Nix development shell (fallback) -nix-shell: - @if [ -f "flake.nix" ]; then nix develop; else echo "No flake.nix"; fi - # ═══════════════════════════════════════════════════════════════════════════════ # HYBRID AUTOMATION # ═══════════════════════════════════════════════════════════════════════════════ diff --git a/flake.nix b/flake.nix deleted file mode 100644 index f6c1adc..0000000 --- a/flake.nix +++ /dev/null @@ -1,170 +0,0 @@ -# SPDX-License-Identifier: MPL-2.0 -# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) -# -# Nix flake for a2ml-validate-action -# -# NOTE: guix.scm is the PRIMARY development environment. This flake is provided -# as a FALLBACK for contributors who use Nix instead of Guix. The .envrc checks -# for Guix first, then falls back to Nix. -# -# Usage: -# nix develop # Enter development shell -# nix build # Build the project -# nix flake check # Run checks -# nix flake show # Show flake outputs -# -# With direnv (.envrc already configured): -# direnv allow # Auto-enters shell on cd -# -# TODO: Replace a2ml-validate-action and with actual values. - -{ - description = "a2ml-validate-action — RSR-compliant project"; - - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - flake-utils.url = "github:numtide/flake-utils"; - }; - - outputs = { self, nixpkgs, flake-utils }: - flake-utils.lib.eachSystem [ "x86_64-linux" "aarch64-linux" ] (system: - let - pkgs = import nixpkgs { inherit system; }; - - # Common development tools present in every RSR project. - commonTools = with pkgs; [ - git - just - nickel - curl - bash - coreutils - ]; - - # --------------------------------------------------------------- - # Language-specific packages: uncomment the stacks you need. - # --------------------------------------------------------------- - # - # Rust: - # rustc cargo clippy rustfmt rust-analyzer - # - # Elixir: - # elixir erlang - # - # Gleam: - # gleam erlang - # - # Zig: - # zig zls - # - # Haskell: - # ghc cabal-install haskell-language-server - # - # Idris2: - # idris2 - # - # OCaml: - # ocaml dune_3 ocaml-lsp - # - # ReScript (via Deno): - # deno - # - # Julia: - # julia - # - # Ada/SPARK: - # gnat gprbuild - # - # --------------------------------------------------------------- - languageTools = with pkgs; [ - # TODO: Uncomment or add packages for your stack. - # Example for a Rust project: - # rustc - # cargo - # clippy - # rustfmt - # rust-analyzer - ]; - - in - { - # --------------------------------------------------------------- - # Development shell — `nix develop` - # --------------------------------------------------------------- - devShells.default = pkgs.mkShell { - name = "a2ml-validate-action-dev"; - - buildInputs = commonTools ++ languageTools; - - # Environment variables available inside the shell. - env = { - PROJECT_NAME = "a2ml-validate-action"; - RSR_TIER = "infrastructure"; - }; - - shellHook = '' - echo "" - echo " a2ml-validate-action — development shell" - echo " Nix: $(nix --version 2>/dev/null || echo 'unknown')" - echo " Just: $(just --version 2>/dev/null || echo 'not found')" - echo "" - echo " Run 'just' to see available recipes." - echo "" - - # Source .envrc manually when direnv is not managing the shell. - # This keeps project env vars (PROJECT_NAME, DATABASE_URL, etc.) - # consistent whether you enter via 'nix develop' or 'direnv allow'. - if [ -z "''${DIRENV_IN_ENVRC:-}" ] && [ -f .envrc ]; then - # Only source the non-nix parts to avoid recursion. - export PROJECT_NAME="a2ml-validate-action" - export RSR_TIER="infrastructure" - if [ -f .env ]; then - set -a - . .env - set +a - fi - fi - ''; - }; - - # --------------------------------------------------------------- - # Package — `nix build` - # --------------------------------------------------------------- - packages.default = pkgs.stdenv.mkDerivation { - pname = "a2ml-validate-action"; - version = "0.1.0"; - - src = self; - - # TODO: Replace with real build instructions. - # Examples: - # - # Rust (use rustPlatform.buildRustPackage instead of stdenv): - # packages.default = pkgs.rustPlatform.buildRustPackage { ... }; - # - # Elixir (use mixRelease): - # packages.default = pkgs.beamPackages.mixRelease { ... }; - # - # Zig: - # buildPhase = "zig build -Doptimize=ReleaseSafe"; - - buildPhase = '' - echo "TODO: Add build commands for a2ml-validate-action" - ''; - - installPhase = '' - mkdir -p $out/share/doc - cp README.adoc $out/share/doc/ 2>/dev/null || true - ''; - - meta = with pkgs.lib; { - description = ""; - homepage = "https://github.com/hyperpolymath/a2ml-validate-action"; - license = licenses.mpl20; # MPL-2.0 extends MPL-2.0 - maintainers = []; - platforms = [ "x86_64-linux" "aarch64-linux" ]; - }; - }; - } - ); -}