aboutsummaryrefslogtreecommitdiffhomepage
path: root/org/config_env.org
diff options
context:
space:
mode:
authorRalph Amissah <ralph.amissah@gmail.com>2023-11-04 12:35:14 -0400
committerRalph Amissah <ralph.amissah@gmail.com>2023-11-04 12:35:14 -0400
commitf9be4ab4c1b364481d9f92dc6b5d3306206407c9 (patch)
treebce1239e03430259b7126d331a681c85c3141424 /org/config_env.org
parentupdates incl. ldc-1.35.0, direnv-2.4.0 (diff)
nix housekeepingdoc-reform_v0.12.0
Diffstat (limited to 'org/config_env.org')
-rw-r--r--org/config_env.org48
1 files changed, 32 insertions, 16 deletions
diff --git a/org/config_env.org b/org/config_env.org
index cfd636a..cb24dae 100644
--- a/org/config_env.org
+++ b/org/config_env.org
@@ -24,6 +24,9 @@
#+HEADER: :tangle ../.envrc
#+BEGIN_SRC sh
+if [ -f .envrc-git-init ]; then
+ source_env_if_exists .envrc-git-init || source .envrc-git-init
+fi
if [ -f .envrc-local ]; then
source_env_if_exists .envrc-local || source .envrc-local
fi
@@ -35,7 +38,9 @@ fi
** .envrc-nix
- https://github.com/nix-community/nix-direnv
- - source_url "https://raw.githubusercontent.com/nix-community/nix-direnv/${NixDirEnvVersion}/direnvrc" "sha256-0000000000000000000000000000000000000000000="
+ - source_url
+ - direnv fetchurl "https://raw.githubusercontent.com/nix-community/nix-direnv/<<direnv-version>>/direnvrc" "<<direnv-sha>>"
+ - ${NixDirEnvVersion}
#+HEADER: :tangle ../.envrc-nix
#+BEGIN_SRC sh
@@ -96,30 +101,20 @@ NixDirEnvSHA="sha256-0000000000000000000000000000000000000000000="
direnv fetchurl https://raw.githubusercontent.com/nix-community/nix-direnv/${NixDirEnvVersion}/direnvrc
#+END_SRC
-** .envrc-local CHECK MODIFY
+** .envrc-git-init
-- bespoke modify appropriately and generate if needed
-
-#+HEADER: :tangle ../.envrc-local
+#+HEADER: :tangle ../.envrc-git-init
#+HEADER: :noweb yes
#+BEGIN_SRC sh
if [[ ! -d ./.git ]]; then
git init
git add .
fi
-echo '
- .envrc-local echo ❯❯
-
- ❯❯ nix flake update && nix flake check --show-trace && nix flake show && nix develop ".#devShell" -c $SHELL
+#+END_SRC
- ❯❯ nix develop
- ❯❯ nix develop -c $SHELL
- ❯❯ nix develop ".#dsh-overlay-ldc" --print-build-logs
+** .envrc-local CHECK MODIFY
- ❯❯ nix build
- ❯❯ nix build ".#default" --print-build-logs
-'
-#+END_SRC
+- bespoke modify appropriately and generate if needed
#+HEADER: :tangle ../.envrc-local_
#+HEADER: :noweb yes
@@ -141,6 +136,27 @@ export SpineDBpath=/var/www/sqlite
#export SpineDBpath=/srv/www/spine/sqlite
#+END_SRC
+#+HEADER: :tangle-NO ../.envrc-local
+#+HEADER: :noweb yes
+#+BEGIN_SRC sh
+if [[ ! -d ./.git ]]; then
+ git init
+ git add .
+fi
+echo '
+ .envrc-local echo ❯❯
+
+ ❯❯ nix flake update && nix flake check --show-trace && nix flake show && nix develop ".#devShell" -c $SHELL
+
+ ❯❯ nix develop
+ ❯❯ nix develop -c $SHELL
+ ❯❯ nix develop ".#dsh-overlay-ldc" --print-build-logs
+
+ ❯❯ nix build
+ ❯❯ nix build ".#default" --print-build-logs
+'
+#+END_SRC
+
#+BEGIN_SRC sh
#export NIX_PATH=/nix/var/nix/profiles/per-user/root/channels/nixos
#export NIX_PATH=/srv/nix/nixpkgs