diff options
Diffstat (limited to 'org/config_env.org')
| -rw-r--r-- | org/config_env.org | 33 |
1 files changed, 28 insertions, 5 deletions
diff --git a/org/config_env.org b/org/config_env.org index 2a2dac1..2fa1f25 100644 --- a/org/config_env.org +++ b/org/config_env.org @@ -33,12 +33,15 @@ fi #+NAME: envrc #+HEADER: :tangle ../.envrc +#+HEADER: :shebang "# -*- mode: sh -*-" #+BEGIN_SRC shell 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 +elif [ -f .envrc-local_ ]; then + source_env_if_exists .envrc-local_ || source .envrc-local_ fi if [ -f .envrc-nix ]; then source_env_if_exists .envrc-nix || source .envrc-nix @@ -53,6 +56,7 @@ fi - ${NixDirEnvVersion} #+HEADER: :tangle ../.envrc-nix +#+HEADER: :shebang "# -*- mode: nix -*-" #+BEGIN_SRC shell NIX_ENFORCE_PURITY=1 # - https://github.com/nix-community/nix-direnv @@ -121,7 +125,9 @@ echo ' ❯❯ ${SpineBIN} -v --source --pod --latex --latex-init --epub --html --html-link-pdf --html-link-curate --html-link-markup --curate --output=${SpineOUT} ${SpinePOD}/* ❯❯ ${SpineBIN} -v --sqlite-db-create --sqlite-db-filename=${SpineSQLdb} --sqlite-db-path=./_tmp-db - ❯❯ ${SpineBIN} -v --sqlite-update --sqlite-db-filename=${SpineSQLdb} --sqlite-db-path=./_tmp-db ./markup/pod/* + ❯❯ ${SpineBIN} -v --sqlite-update --sqlite-db-filename=${SpineSQLdb} --sqlite-db-path=./_tmp-db ${SpinePOD}/* + + ❯❯ ${SpineBIN} --source --pod --curate --text --latex --epub --html --manifest --html-link-search --html-link-pdf --html-link-text --html-link-curate --html-link-markup --html-link-source --html-link-pod --html-link-metadata --cgi-sqlite-search-filename="${SpineCGIform}" --cgi-url-action="${SpineSearchActionRemote}" --sqlite-db-path="${SpineDBpath}" --sqlite-db-filename="${SpineSQLdb}" --www-url-doc-root=${SpineURLdocRoot} --set-papersize="a4,letter" --output=${SpineOUT} ${SpinePOD}/* ' echo "• ❯❯ ${SpineBIN} -v --source --pod --epub --html --html-link-curate --html-link-markup --curate --output=${SpineOUT} ${SpinePOD}/* @@ -132,6 +138,7 @@ echo "• ** .envrc-git-init #+HEADER: :tangle ../.envrc-git-init +#+HEADER: :shebang "# -*- mode: sh -*-" #+HEADER: :noweb yes #+BEGIN_SRC shell if [[ ! -d ./.git ]]; then @@ -140,11 +147,25 @@ if [[ ! -d ./.git ]]; then fi #+END_SRC +** ,version (project & git version info) + +#+HEADER: :tangle ../,version +#+HEADER: :noweb yes +#+HEADER: :tangle-mode (identity #o755) +#+HEADER: :shebang #!/usr/bin/env sh +#+BEGIN_SRC shell +SpineProjVer=`rg "Version\((\d+), (\d+), (\d+)\)" views/version.txt | sed -E 's/.*([0-9]+), ([0-9]+), ([0-9]+).*/spine-v\1.\2.\3/'` && \ + SpineGitVer=`git describe | sed "s/^[a-z_-]\+\([0-9.]\+\)/\1/" | sed "s/\([^-]*-g\)/r\1/" | sed "s/-/./g"` && \ + SpineGitBranch=`git branch --show-current` && \ + echo "❯❯ $SpineProjVer - ($SpineGitBranch: $SpineGitVer)" +#+END_SRC + ** .envrc-local CHECK MODIFY - bespoke modify appropriately and generate if needed #+HEADER: :tangle ../.envrc-local_ +#+HEADER: :shebang "# -*- mode: sh -*-" #+HEADER: :noweb yes #+BEGIN_SRC shell export SpineVER=$(git describe --long --tags | sed 's/^[ a-z_-]\+\([0-9.]\+\)/\1/;s/\([^-]*-g\)/r\1/;s/-/./g') @@ -157,13 +178,17 @@ export SpineBIN=./result/bin/spine #export SpineBIN=./bin/spine-dmd # ❯❯ location of source files: export SpineDOC=../sisudoc-spine-samples +#export SpineDOC=./sisudoc-spine-samples # ❯❯ location of source files pod: -export SpinePOD=${SpineDOC}/markup/pod +export SpinePOD=${SpineDOC}/markup/pod-samples/pod # ❯❯ sisudoc-spine output processing path: export SpineOUT=./OUTPUT_TEST_sisudocSpine # ❯❯ sisudoc-spine output processing path (web server e.g.): #export SpineOUT=/srv/www/spine #export SpineOUTversioned=${SpineOUT}/${SpineVER} +# ❯❯ www url doc root +export SpineURLdocRoot='http://localhost' +# export SpineURLdocRoot='https://sisudoc.org' # ❯❯ path configured for cgi search form: export SpineSearchActionLocal='http://localhost/spine_search' export SpineSearchActionRemote='https://sisudoc.org/spine_search' @@ -178,7 +203,7 @@ export SpineDBpath=/var/www/sqlite #export SpineDBpath=/srv/www/spine/sqlite #+END_SRC -* versions GET +* org includes - versions GET ** direnv #+NAME: direnv_version @@ -234,8 +259,6 @@ export SpineDBpath=/var/www/sqlite <<./sisudoc_spine_version_info_and_doc_header_including_copyright_and_license.org:spine_project_version()>> #+END_SRC -** year - #+NAME: year #+HEADER: :noweb yes #+BEGIN_SRC emacs-lisp |
