From 08e51e75cab75abc20992faed5fd8215d1b48d28 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Tue, 20 Apr 2021 19:13:21 -0400 Subject: spine_build_scaffold: nix related housekeeping - mkDub.nix (dub2nix) use lib, stdenv.lib deprecated - .envrc stop using lorri - .envrc-local_ set local variables as needed --- org/spine_build_scaffold.org | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) (limited to 'org') diff --git a/org/spine_build_scaffold.org b/org/spine_build_scaffold.org index c2eb6d5..a6bbd72 100644 --- a/org/spine_build_scaffold.org +++ b/org/spine_build_scaffold.org @@ -2114,6 +2114,15 @@ make modificatons if desired *** .envrc #+BEGIN_SRC nix :tangle ../.envrc +NIX_ENFORCE_PURITY=0 +if [ -e .envrc-local ]; then # source an additional user-specific .envrc in ./.envrc-local + source .envrc-local +fi +#+END_SRC + +- lorri? + +#+BEGIN_SRC nix :NO-tangle ../.envrc if type lorri &>/dev/null; then echo "direnv: using lorri from PATH ($(type -p lorri))" eval "$(lorri direnv)" @@ -2171,6 +2180,11 @@ watch_file flake.nix eval "$(nix print-dev-env)" # echo $NIX_BUILD_TOP echo " `nix-instantiate --find-file nixpkgs`" +export PROJ=<> +echo "PROJ=<>" +echo '$PROJ/doc-reform/result/bin/spine --very-verbose --pod --source --output="/tmp/www" $PROJ/doc-reform-markup/spine-markup-samples/markup/pod/*' +echo '$PROJ/doc-reform/result/bin/spine --very-verbose --html --epub --output="/tmp/www" $PROJ/doc-reform-markup/spine-markup-samples/markup/pod/*' +echo '$PROJ/doc-reform/result/bin/spine --very-verbose --sqlite-discrete --output="/tmp/www" $PROJ/doc-reform-markup/spine-markup-samples/markup/pod/*' #+END_SRC **** nixpkgs_path SETUP @@ -2197,6 +2211,15 @@ echo " `nix-instantiate --find-file nixpkgs`" /nixpkgs-ra/nixpkgs #+END_SRC +***** project path options + +- local path SET WARN + +#+NAME: project_path_local +#+BEGIN_SRC nix +/grotto-ra/repo/git.repo/projects/project-spine +#+END_SRC + ** flake :flake: - flake.nix @@ -2548,6 +2571,7 @@ mkDubDerivation rec { #+BEGIN_SRC nix :tangle ../spine.nix :tangle-mode (identity #o755) :shebang "#!/usr/bin/env -S nix-build" { pkgs ? import {}, stdenv ? pkgs.stdenv, + lib ? pkgs.lib, ldc ? null, dcompiler ? pkgs.ldc, dub ? pkgs.dub @@ -2620,6 +2644,7 @@ aria2c https://raw.githubusercontent.com/lionello/dub2nix/master/mkDub.nix ./nix #+BEGIN_SRC nix :tangle ../nix/mkDub.nix { pkgs ? import {}, stdenv ? pkgs.stdenv, + lib ? pkgs.lib, ldc ? null, dcompiler ? pkgs.ldc, dub ? pkgs.dub @@ -2632,7 +2657,7 @@ aria2c https://raw.githubusercontent.com/lionello/dub2nix/master/mkDub.nix ./nix #+NAME: mkDub_nix #+BEGIN_SRC nix assert dcompiler != null; -with stdenv; +with stdenv lib; let # Filter function to remove the .dub package folder from src filterDub = name: type: let baseName = baseNameOf (toString name); in ! ( -- cgit v1.2.3