aboutsummaryrefslogtreecommitdiffhomepage
path: root/org
diff options
context:
space:
mode:
Diffstat (limited to 'org')
-rw-r--r--org/config_env.org17
-rw-r--r--org/config_git.org3
-rw-r--r--org/config_nix.org44
-rw-r--r--org/in_source_files.org10
-rw-r--r--org/nix-develop-dlang-shared.org111
-rw-r--r--org/nixpkgs_overlays_d_related.org21
-rw-r--r--org/ocda.org18
-rw-r--r--org/out_src_pod.org39
-rw-r--r--org/spine_info.org32
9 files changed, 192 insertions, 103 deletions
diff --git a/org/config_env.org b/org/config_env.org
index db6af9d..ec6a1d5 100644
--- a/org/config_env.org
+++ b/org/config_env.org
@@ -80,11 +80,11 @@ echo '
• nix develop
❯❯ nix develop ".#" --print-build-logs -c zsh
• nix develop using nixpkgs
- ❯❯ nix develop ".#dsh-nixpkgs-dmd-dub" --print-build-logs -c zsh
- ❯❯ nix develop ".#dsh-nixpkgs-ldc-dub" --print-build-logs -c zsh
+ ❯❯ nix develop ".#dsh-nixpkgs-dmd" --print-build-logs -c zsh
+ ❯❯ nix develop ".#dsh-nixpkgs-ldc" --print-build-logs -c zsh
• nix develop using package overlays: (dmd-<<dmd_version>>, ldc-<<ldc_version>>, dub-<<dub_version>>, dtools-<<dtools_version>>)
- ❯❯ nix develop ".#dsh-overlay-dmd-dub" --print-build-logs -c zsh
- ❯❯ nix develop ".#dsh-overlay-ldc-dub" --print-build-logs -c zsh
+ ❯❯ nix develop ".#dsh-overlay-dmd" --print-build-logs -c zsh
+ ❯❯ nix develop ".#dsh-overlay-ldc" --print-build-logs -c zsh
❯❯ nix flake show
• to build project:
@@ -102,10 +102,10 @@ echo '
• to build using dub on nix (get dependencies by setting your development environment):
- ❯❯ nix develop ".#dsh-nixpkgs-dmd-dub" --print-build-logs -c zsh
+ ❯❯ nix develop ".#dsh-nixpkgs-dmd" --print-build-logs -c zsh
❯❯ dub --verbose --compiler=dmd --config=dmd
- ❯❯ nix develop ".#dsh-nixpkgs-ldc-dub" --print-build-logs -c zsh
+ ❯❯ nix develop ".#dsh-nixpkgs-ldc" --print-build-logs -c zsh
❯❯ dub --verbose --compiler=ldmd2 --config=ldmd2
• for develop environment & build options
@@ -119,6 +119,9 @@ echo '
❯❯ ${SpineBIN} -v --source --pod --epub --html --html-link-curate --html-link-markup --curate --output=${SpineOUT} ${SpinePOD}/*
❯❯ ${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/*
'
echo "•
❯❯ ${SpineBIN} -v --source --pod --epub --html --html-link-curate --html-link-markup --curate --output=${SpineOUT} ${SpinePOD}/*
@@ -175,7 +178,7 @@ export SpineDBpath=/var/www/sqlite
#export SpineDBpath=/srv/www/spine/sqlite
#+END_SRC
-* SHARED versions
+* versions GET
** direnv
#+NAME: direnv_version
diff --git a/org/config_git.org b/org/config_git.org
index b997923..66383ad 100644
--- a/org/config_git.org
+++ b/org/config_git.org
@@ -37,8 +37,6 @@
!.envrc
!.envrc-nix
!.envrc-git-init
-!.env
-!.env/**
!nix-overlays
!nix-overlays/**
!README.md
@@ -50,6 +48,7 @@
!configuration.txt
!*.json
!*.sdl
+!*.md
!meson.build
!tangle
!*.org
diff --git a/org/config_nix.org b/org/config_nix.org
index 3ec97d0..3f101a0 100644
--- a/org/config_nix.org
+++ b/org/config_nix.org
@@ -251,7 +251,7 @@
];
inherit shellHook;
};
- dsh-nixpkgs-dmd-dub = mkShell {
+ dsh-nixpkgs-dmd = mkShell {
name = "spine-<<spine_version>> base dev shell";
inherit shell;
inherit devEnv;
@@ -264,7 +264,7 @@
];
inherit shellHook;
};
- dsh-nixpkgs-ldc-dub = mkShell {
+ dsh-nixpkgs-ldc = mkShell {
name = "spine-<<spine_version>> base dev shell";
inherit shell;
inherit devEnv;
@@ -277,7 +277,7 @@
];
inherit shellHook;
};
- dsh-overlay-dmd-dub = mkShell {
+ dsh-overlay-dmd = mkShell {
name = "spine-<<spine_version>> base dev shell, dmd-<<dmd_version>>, dub-<<dub_version>> - dtools-<<dtools_version>>";
inherit shell;
inherit devEnv;
@@ -290,7 +290,7 @@
];
inherit shellHook;
};
- dsh-overlay-ldc-dub = mkShell {
+ dsh-overlay-ldc = mkShell {
name = "spine-<<spine_version>> base dev shell, ldc-<<ldc_version>>, dub-<<dub_version>> - dtools-<<dtools_version>>";
inherit shell;
inherit devEnv;
@@ -717,7 +717,7 @@ github:nixos/nixpkgs
** .env/echo-nixNote CHECK MODIFY
*** notes on nix commands
-#+HEADER: :tangle ../.env/nix-commands
+#+HEADER: :tangle-NO ../.env/nix-commands
#+BEGIN_SRC text
- nix flake update && nix flake check --show-trace && nix flake show && nix develop .#devShell
@@ -742,7 +742,7 @@ nix-shell '<nixpkgs>' -A nix --pure
*** echo-nixNote
-#+HEADER: :tangle ../.env/echo-nixNote
+#+HEADER: :tangle-NO ../.env/echo-nixNote
#+BEGIN_SRC shell
echo '-*- mode: org -*-
@@ -892,13 +892,13 @@ $SpineBIN/spine --show-config --output="$SpineOUTversioned" $SpinePOD
,#+BEGIN_SRC shell
$SpineBIN/spine --very-verbose --sqlite-db-create --output="$SpineOUT" $SpinePOD/*
-$SpineBIN/spine -v --cgi-search-form-codegen --output=$SpineOUT $SpinePOD/*
+# CGI search form is built separately in sisudoc-spine-search-cgi/
$SpineBIN/spine -v --show-config --config=$SpinePOD/.dr
$SpineBIN/spine --html $SpinePOD/*
-$SpineBIN/spine -v --cgi-search-form-codegen --config=$SpinePOD/.dr/config_local_site
+# See sisudoc-spine-search-cgi/README.md for CGI search form build instructions
,#+END_SRC
,*** generate html linked to search form
@@ -967,7 +967,7 @@ webserv:
,*** make search form
,#+BEGIN_SRC shell
-$SpineBIN/spine -v --cgi-search-form-codegen --config=$SpinePOD/.dr/config_local_site
+# CGI search form is built separately - see sisudoc-spine-search-cgi/README.md
,#+END_SRC
,*** latex
@@ -1032,9 +1032,8 @@ postInstall:
echo `ls -la $${out}/bin/spine`
#+END_SRC
-* SHARED
-** versions
-*** spine project VERSION :version:set:project:
+* versions GET
+** spine project VERSION :version:set:project:
#+NAME: spine_version
#+HEADER: :noweb yes
@@ -1042,8 +1041,8 @@ postInstall:
<<./sisudoc_spine_version_info_and_doc_header_including_copyright_and_license.org:spine_project_version()>>
#+END_SRC
-*** dlang overlays
-**** ldc
+** dlang overlays
+*** ldc
#+NAME: ldc_version
#+HEADER: :noweb yes
@@ -1051,7 +1050,7 @@ postInstall:
<<./nix-develop-dlang-shared.org:ldc-version()>>
#+END_SRC
-**** dmd
+*** dmd
#+NAME: dmd_version
#+HEADER: :noweb yes
@@ -1059,7 +1058,7 @@ postInstall:
<<./nix-develop-dlang-shared.org:dmd-version()>>
#+END_SRC
-**** dub
+*** dub
#+NAME: dub_version
#+HEADER: :noweb yes
@@ -1067,7 +1066,7 @@ postInstall:
<<./nix-develop-dlang-shared.org:dub-version()>>
#+END_SRC
-**** dtools
+*** dtools
#+NAME: dtools_version
#+HEADER: :noweb yes
@@ -1075,15 +1074,14 @@ postInstall:
<<./nix-develop-dlang-shared.org:dtools-version()>>
#+END_SRC
-*** empty sha56 hash
+** sha256 blank hash
-#+NAME: blank_hash
+#+NAME: sha256-blank
#+BEGIN_SRC nix
-sha256-0000000000000000000000000000000000000000000=
+<<./nix-develop-dlang-shared.org:sha256-blank()>>
#+END_SRC
-#+NAME: assumed_hash
+#+NAME: blank_hash
#+BEGIN_SRC nix
-sha256-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=
+<<./nix-develop-dlang-shared.org:sha256-blank()>>
#+END_SRC
-
diff --git a/org/in_source_files.org b/org/in_source_files.org
index cdd220f..e83729f 100644
--- a/org/in_source_files.org
+++ b/org/in_source_files.org
@@ -374,7 +374,7 @@ template spineRawMarkupContent() {
sourcefile_body_content = _cii.contents;
insert_file_list_get = _cii.insert_files.dup;
images_list_get = _cii.images.dup;
- } else if (_opt_action.source || _opt_action.pod) {
+ } else if (_opt_action.source_or_pod) {
auto ins = Inserts();
ST_contents_inserts_images _cii
= ins.scan_master_src_for_insert_files_and_import_content(_opt_action, sourcefile_body_content, fn_src);
@@ -630,7 +630,7 @@ if (code_block_status == codeBlock.curly) {
markup_sourcesubfile_insert_content.length
);
}
- if (_opt_action.source || _opt_action.pod) {
+ if (_opt_action.source_or_pod) {
_images ~= _extract_images(markup_sourcesubfile_insert_content);
}
auto ins = Inserts();
@@ -646,7 +646,7 @@ if (code_block_status == codeBlock.curly) {
+/
} else {
contents_insert ~= line; // images to extract for image list?
- if (_opt_action.source || _opt_action.pod) {
+ if (_opt_action.source_or_pod) {
string[] _image_linelist = _extract_images(line);
if (_image_linelist.length > 0) {
_images ~= _image_linelist;
@@ -735,7 +735,7 @@ if (code_block_status == codeBlock.curly) {
fn_src_insert.to!string
);
contents ~= contents_insert_st.insert_contents;
- if (_opt_action.source || _opt_action.pod) {
+ if (_opt_action.source_or_pod) {
string[] _image_linelist = _extract_images(contents_insert_st.images);
if (_image_linelist.length > 0) {
_images ~= _image_linelist;
@@ -753,7 +753,7 @@ if (code_block_status == codeBlock.curly) {
+/
} else {
contents ~= line;
- if (_opt_action.source || _opt_action.pod) {
+ if (_opt_action.source_or_pod) {
string[] _image_linelist = _extract_images(line);
if (_image_linelist.length > 0) {
_images ~= _image_linelist;
diff --git a/org/nix-develop-dlang-shared.org b/org/nix-develop-dlang-shared.org
index f0a7aac..2a2f66d 100644
--- a/org/nix-develop-dlang-shared.org
+++ b/org/nix-develop-dlang-shared.org
@@ -17,20 +17,51 @@
* nix
** direnv
+*** NOTES to update direnv in .envrc-nix
+
+- https://github.com/nix-community/nix-direnv
+
+check for latest version:
+
+- https://github.com/nix-community/nix-direnv/releases
+
+update direnv version and sha hash:
+- emacs org/nix-develop-dlang-shared.org
+
+re-tangle file:
+
+- emacs org/config_env.org
+ updates: .envrc-nix
+
+update flake.lock:
+- nix flake update && nix flake check && nix flake show
+
*** version SET
#+NAME: direnv-version
#+BEGIN_SRC org
-<<direnv_version_3_0_6>>
+<<direnv_version_3_0_7>>
#+END_SRC
#+NAME: direnv-hash
#+BEGIN_SRC org
-<<direnv_hash_3_0_6>>
+<<direnv_hash_3_0_7>>
#+END_SRC
*** versions
+**** 3.0.7
+
+#+NAME: direnv_version_3_0_7
+#+BEGIN_SRC org
+3.0.7
+#+END_SRC
+
+#+NAME: direnv_hash_3_0_7
+#+BEGIN_SRC org
+sha256-bn8WANE5a91RusFmRI7kS751ApelG02nMcwRekC/qzc=
+#+END_SRC
+
**** 3.0.6
#+NAME: direnv_version_3_0_6
@@ -81,6 +112,36 @@ sha256-XQzUAvL6pysIJnRJyR7uVpmUSZfc7LSgWQwq/4mBr1U=
* dlang
** ldc
+*** NOTES to update ldc
+
+check for latest version:
+
+update ldc version and sha hash:
+- emacs ./org/nix-develop-dlang-shared.org
+
+re-tangle files:
+- emacs ./org/nixpkgs_overlays_d_related.org
+ updates: nix-overlays/ldc/package.nix
+- emacs ./org/config_nix.org
+ updates: flake.nix
+- emacs ./org/config_env.org
+ updates: .envrc-nix
+
+update flake.lock:
+- nix flake update && nix flake check && nix flake show
+
+build:
+- nix build ".#spine-overlay-ldc" --print-build-logs
+
+adjust nix overlay if required (to get started):
+- git clone --depth 1 https://github.com/NixOS/nixpkgs
+- find ./nixpkgs/pkgs/ -type d -name "ldc"
+ ./nixpkgs/pkgs/by-name/ld/ldc
+- compare with overlay:
+ ./nix-overlays/ldc
+- overlay is tangled from:
+ emacs ./org/nixpkgs_overlays_d_related.org
+
*** version SET
**** version & sha256 nix composite
@@ -94,20 +155,41 @@ sha256 = "<<ldc-hash>>";
#+NAME: ldc-version
#+BEGIN_SRC org
-<<ldc_version_1_40_1>>
+<<ldc_version_1_41_0>>
#+END_SRC
#+NAME: ldc-hash
#+BEGIN_SRC org
-<<ldc_hash_1_40_1>>
+<<ldc_hash_1_41_0>>
#+END_SRC
#+NAME: ldc-llvm-set
#+BEGIN_SRC org
-<<ldc_llvm_set_1_40_1>>
+<<ldc_llvm_set_1_41_0>>
#+END_SRC
*** versions
+**** 1.41 OK ✓
+***** 1.41.0 OK ✓
+
+ - nix-prefetch-url --unpack https://github.com/ldc-developers/ldc/archive/refs/tags/v1.41.0.tar.gz
+ - nix-prefetch-url --unpack https://github.com/ldc-developers/ldc/releases/download/v${version}/ldc-${version}-src.tar.gz
+
+#+NAME: ldc_version_1_41_0
+#+BEGIN_SRC nix
+1.41.0
+#+END_SRC
+
+#+NAME: ldc_hash_1_41_0
+#+BEGIN_SRC nix
+sha256-6LcpY3LSFK4KgEiGrFp/LONu5Vr+/+vI04wEEpF3s+s=
+#+END_SRC
+
+#+NAME: ldc_llvm_set_1_41_0
+#+BEGIN_SRC nix
+llvm_20
+#+END_SRC
+
**** 1.40 OK ✓
***** 1.40.1 OK ✓
@@ -242,42 +324,45 @@ sha256-/bs3bwgkLZF5IqaiKnc5gCF/r6MQBG/F1kWUkK8j2s0=
#+END_SRC
** dmd
+
+- https://github.com/dlang/dmd/tags
+
*** version SET
#+NAME: dmd-version
#+BEGIN_SRC org
-<<dmd_version_2_110_0>>
+<<dmd_version_2_111_0>>
#+END_SRC
#+NAME: dmd-hash
#+BEGIN_SRC org
-<<dmd_hash_2_110_0>>
+<<dmd_hash_2_111_0>>
#+END_SRC
#+NAME: phobos-hash
#+BEGIN_SRC org
-<<phobos_hash_2_110_0>>
+<<phobos_hash_2_111_0>>
#+END_SRC
*** versions
**** 2.111.0 OK ✓
-- nix-prefetch-url --unpack https://github.com/dlang/dmd/archive/refs/tags/v2.111.0-beta.1.tar.gz
-- nix-prefetch-url --unpack https://github.com/dlang/phobos/archive/refs/tags/v2.111.0-beta.1.tar.gz
+- nix-prefetch-url --unpack https://github.com/dlang/dmd/archive/refs/tags/v2.111.0.tar.gz
+- nix-prefetch-url --unpack https://github.com/dlang/phobos/archive/refs/tags/v2.111.0.tar.gz
#+NAME: dmd_version_2_111_0
#+BEGIN_SRC nix
-2.111.0-beta.1
+2.111.0
#+END_SRC
#+NAME: phobos_hash_2_111_0
#+BEGIN_SRC nix
-sha256-yPmstS52J0BboR++9nYaeUq2mAJrFuUjxxi2BGgGCUY=
+sha256-9jySZbODoL8sULhYKj/l4+c/uiG5xY2dO240k9XQtPk=
#+END_SRC
#+NAME: dmd_hash_2_111_0
#+BEGIN_SRC nix
-sha256-MfGcno6o+GXZTWyWZ0kGYtMcMPuj2VgQd5I+nPKz1I4=
+sha256-2bjsGa9nTny818dLRV6LKkes+Ycq8W+PFjwhGVrD5TM=
#+END_SRC
**** 2.110.0 OK ✓
diff --git a/org/nixpkgs_overlays_d_related.org b/org/nixpkgs_overlays_d_related.org
index 14d2383..1b89d89 100644
--- a/org/nixpkgs_overlays_d_related.org
+++ b/org/nixpkgs_overlays_d_related.org
@@ -944,7 +944,9 @@ stdenv.mkDerivation (finalAttrs: {
rm dmd/compiler/test/runnable/gdb4149.d
rm dmd/compiler/test/runnable/gdb4181.d
rm dmd/compiler/test/compilable/ddocYear.d
- rm dmd/compiler/test/fail_compilation/needspkgmod.d
+ rm dmd/compiler/test/compilable/sarif_success_test.d
+ rm dmd/compiler/test/fail_compilation/sarif_test.d
+ rm dmd/compiler/test/fail_compilation/sarifmultiple_test.d
# Disable tests that rely on objdump whitespace until fixed upstream:
# https://issues.dlang.org/show_bug.cgi?id=23317
@@ -956,9 +958,9 @@ stdenv.mkDerivation (finalAttrs: {
substituteInPlace dmd/compiler/test/dshell/test6952.d --replace-fail "/usr/bin/env bash" "${bash}/bin/bash"
'' + lib.optionalString stdenv.hostPlatform.isLinux ''
substituteInPlace phobos/std/socket.d --replace-fail "assert(ih.addrList[0] == 0x7F_00_00_01);" ""
- '' + lib.optionalString stdenv.hostPlatform.isDarwin ''
- substituteInPlace phobos/std/socket.d --replace-fail "foreach (name; names)" "names = []; foreach (name; names)"
- '';
+ ''; # + lib.optionalString stdenv.hostPlatform.isDarwin ''
+ # substituteInPlace phobos/std/socket.d --replace-fail "foreach (name; names)" "names = []; foreach (name; names)"
+ #'';
nativeBuildInputs = [
makeWrapper
@@ -1307,7 +1309,7 @@ stdenv.mkDerivation (finalAttrs: {
})
#+END_SRC
-*** dcompiler SET
+*** dcompiler
#+NAME: dcompiler
#+BEGIN_SRC nix
@@ -1520,9 +1522,9 @@ Adapted from https://github.com/dlang/tools/commit/6c6a042d1b08e3ec1790bd07a7f69
$(ROOT)/catdoc$(DOTEXE) \
#+END_SRC
-** versions SET
+** versions GET
*** direnv
-***** select version SET OK ✓
+***** select version
#+NAME: direnv_version
#+HEADER: :noweb yes
@@ -1543,7 +1545,7 @@ Adapted from https://github.com/dlang/tools/commit/6c6a042d1b08e3ec1790bd07a7f69
<<./nix-develop-dlang-shared.org:ldc-version-info()>>
#+END_SRC
-***** select version SET OK ✓
+***** selected version
#+NAME: ldc_version
#+HEADER: :noweb yes
@@ -1562,6 +1564,7 @@ Adapted from https://github.com/dlang/tools/commit/6c6a042d1b08e3ec1790bd07a7f69
#+END_SRC
*** dmd
+**** selected version
#+NAME: dmd_version
#+HEADER: :noweb yes
@@ -1580,6 +1583,7 @@ Adapted from https://github.com/dlang/tools/commit/6c6a042d1b08e3ec1790bd07a7f69
#+END_SRC
*** dub
+**** selected version
#+NAME: dub_version
#+HEADER: :noweb yes
@@ -1593,6 +1597,7 @@ Adapted from https://github.com/dlang/tools/commit/6c6a042d1b08e3ec1790bd07a7f69
#+END_SRC
*** dtools
+**** selected version
#+NAME: dtools_version
#+HEADER: :noweb yes
diff --git a/org/ocda.org b/org/ocda.org
index 148edf8..2509725 100644
--- a/org/ocda.org
+++ b/org/ocda.org
@@ -1,6 +1,7 @@
-*- mode: org -*-
#+TITLE: sisudoc spine (doc_reform) object-centric document abstraction
#+DESCRIPTION: documents - structuring, publishing in multiple formats & search
+#+SUMMARY: process markup document, create document abstraction
#+FILETAGS: :spine:abstraction:
#+AUTHOR: Ralph Amissah
#+EMAIL: [[mailto:ralph.amissah@gmail.com][ralph.amissah@gmail.com]]
@@ -18,7 +19,8 @@
- [[./doc-reform.org][doc-reform.org]] [[./][org/]]
* (Object-Centric) Document Abstraction
-Process markup document, create document abstraction.
+
+- Process markup document, create document abstraction
** _module template_ :module:metadoc_from_src:
@@ -69,7 +71,7 @@ mixin docAbstractionFunctions;
#+END_SRC
** docAbstraction
-*** abstraction summary
+*** _toc_ abstraction summary
#+NAME: docAbstraction
#+HEADER: :noweb yes
@@ -219,7 +221,7 @@ int cnt1 = 1; int cnt2 = 1; int cnt3 = 1;
// abstraction init ↑
#+END_SRC
-*** abstraction init substitutions
+*** debug abstraction init substitutions
#+NAME: docAbstractionInitSubstitutionsDebug
#+HEADER: :noweb yes
@@ -231,8 +233,8 @@ debug (substitutions) {
}
if (conf_make_meta.make.substitute) {
foreach(substitution_pair; conf_make_meta.make.substitute) {
- writeln("regex to match: ", substitution_pair[Substitute.match]);
- writeln("substitution to make: ", substitution_pair[Substitute.markup]);
+ writeln("regex to match: ", substitution_pair[Substitute.match]);
+ writeln("substitution to make: ", substitution_pair[Substitute.markup]);
}
}
if (conf_make_meta.make.bold) {
@@ -250,7 +252,7 @@ debug (substitutions) {
}
#+END_SRC
-*** loop source by line (large block)
+*** _loop_ source by line (large block)
#+NAME: docAbstractionMainLoopSrcByLine
#+HEADER: :noweb yes
@@ -883,7 +885,7 @@ _loopMarkupSrcByLineStruct loopMarkupSrcByLine(
}
#+END_SRC
-*** post loop (consider and segment/break up further in code & org)
+*** _post loop_ (consider and segment/break up further in code & org)
#+NAME: docAbstractionPostMainLoop
#+HEADER: :noweb yes
@@ -1456,7 +1458,7 @@ debug(segnames) {
}
#+END_SRC
-*** return structure
+*** _return structure_
#+NAME: docAbstractionReturnsStruct
#+HEADER: :noweb yes
diff --git a/org/out_src_pod.org b/org/out_src_pod.org
index e72d332..a8a35ad 100644
--- a/org/out_src_pod.org
+++ b/org/out_src_pod.org
@@ -31,7 +31,7 @@ template spinePod() {
<<output_imports>>
void spinePod(T)(T doc_matters) {
<<source_pod_init>>
- if (doc_matters.opt.action.pod) {
+ if (doc_matters.opt.action.source_or_pod) {
try {
{
podArchive_directory_tree(doc_matters, pths_pod);
@@ -105,8 +105,8 @@ assert (doc_matters.src.filename.match(rgx_files.src_fn));
#+BEGIN_SRC d
auto pod_zipMakeReady(M,P,S)(M doc_matters, P pths_pod, S _st) {
auto pth_dr_doc_src = doc_matters.src_path_info;
- if (doc_matters.opt.action.debug_do_pod && doc_matters.opt.action.vox_gt1) {
- writeln(__LINE__, ": ",
+ if (doc_matters.opt.action.vox_gt2) { // correct
+ writeln(__LINE__, ":", __FILE__, ":\n",
doc_matters.src.filename, " -> ",
pths_pod.fn_doc(doc_matters.src.filename, doc_matters.src.language).filesystem_open_zpod
);
@@ -116,7 +116,7 @@ auto pod_zipMakeReady(M,P,S)(M doc_matters, P pths_pod, S _st) {
string[string][string] _digests;
{ // bundle images - get digest
foreach (image; doc_matters.srcs.image_list) {
- debug(podimages) {
+ if (doc_matters.opt.action.vox_gt2) {
writeln(
pth_dr_doc_src.image_root.to!string, "/", image, " -> ",
pths_pod.image_root(doc_matters.src.filename).zpod, "/", image
@@ -139,7 +139,7 @@ auto pod_zipMakeReady(M,P,S)(M doc_matters, P pths_pod, S _st) {
if (doc_matters.opt.action.source_or_pod) {
fn_src_in.copy(fn_src_out_filesystem);
}
- if (doc_matters.opt.action.pod) {
+ if (doc_matters.opt.action.source_or_pod) {
zip = podArchive("file_path_bin", fn_src_in, fn_src_out_pod_zip_base, zip);
}
} else {
@@ -163,7 +163,7 @@ auto pod_zipMakeReady(M,P,S)(M doc_matters, P pths_pod, S _st) {
if (doc_matters.opt.action.source_or_pod) {
fn_src_in.copy(fn_src_out_filesystem);
}
- if (doc_matters.opt.action.pod) {
+ if (doc_matters.opt.action.source_or_pod) {
zip = podArchive("file_path_text", fn_src_in, fn_src_out_pod_zip_base, zip);
}
} else {
@@ -208,7 +208,7 @@ auto pod_zipMakeReady(M,P,S)(M doc_matters, P pths_pod, S _st) {
if (doc_matters.opt.action.source_or_pod) {
pod_filelist_yaml_string.writeln(_pm);
}
- if (doc_matters.opt.action.pod) {
+ if (doc_matters.opt.action.source_or_pod) {
zip = podArchive("string", _pm, fn_src_out_pod_zip_base, zip);
}
}
@@ -228,11 +228,14 @@ auto pod_zipMakeReady(M,P,S)(M doc_matters, P pths_pod, S _st) {
string fn_src_out_filesystem_lng
= pths_pod.fn_doc(doc_matters.src.filename, _lang).filesystem_open_zpod.to!string;
string _sstm = (doc_matters.pod.manifest_path ~ "/media/text/" ~ _lang ~ "/" ~ doc_matters.src.filename);
- // writeln(_sstm);
- if (exists(_sstm)) { // what of language?
- debug(io) { writeln("(io debug) src in found: ", _sstm); }
+ string _pth_file_sstm;
+ if (exists(_sstm)) { _pth_file_sstm = _sstm;
+ } else if (exists(fn_src_in)) { _pth_file_sstm = fn_src_in;
+ }
+ if (exists(_pth_file_sstm)) { // what of language?
+ debug(io) { writeln("(io debug) src in found: ", _pth_file_sstm); }
{ // take DIGEST write to pod file digests.txt
- auto data = (cast(byte[]) (_sstm).read);
+ auto data = (cast(byte[]) (_pth_file_sstm).read);
_digests[_lang]["sstm"] ~= data.sha256Of.toHexString ~ "::" ~ data.length.to!string ~ " - " ~ doc_matters.src.filename ~ " - [" ~ _lang ~ "]";
// writeln(data.sha256Of.toHexString, "::", data.length, " - ", doc_matters.src.filename);
}
@@ -240,11 +243,11 @@ auto pod_zipMakeReady(M,P,S)(M doc_matters, P pths_pod, S _st) {
filelist_src_zpod_arr ~= fn_src_out_inside_pod;
string _pod_to_markup_file = doc_matters.src.pod_name ~ "/" ~ "media/text/" ~ _lang ~ "/" ~ doc_matters.src.filename;
if (doc_matters.opt.action.source_or_pod) {
- _sstm.copy(fn_src_out_filesystem_lng);
+ _pth_file_sstm.copy(fn_src_out_filesystem_lng);
}
- if (doc_matters.opt.action.pod) {
+ if (doc_matters.opt.action.source_or_pod) {
auto _rgx_sstm = regex(r"(?P<path_to_pod>\S+?)(?P<podname>[a-z_-]+)/(?P<from_root>media/text/)(?P<language>\S+?)/(?P<filename>\S+?\.ss[mt])");
- if (auto _x = _sstm.match(_rgx_sstm)){
+ if (auto _x = _pth_file_sstm.match(_rgx_sstm)){
if (doc_matters.src.lng == doc_matters.pod.manifest_list_of_languages[$-1]) { // again wait until all language versions of .ssm parsed
string _path_to_pod = _x.captures["path_to_pod"];
string _podname = _x.captures["podname"];
@@ -259,12 +262,12 @@ auto pod_zipMakeReady(M,P,S)(M doc_matters, P pths_pod, S _st) {
}
}
} else {
- zip = podArchive("file_path_text", _sstm, fn_src_out_pod_zip_base, zip);
+ zip = podArchive("file_path_text", _pth_file_sstm, fn_src_out_pod_zip_base, zip);
}
}
} else {
if (doc_matters.opt.action.debug_do_pod && doc_matters.opt.action.vox_gt1) {
- writeln("WARNING (io) src in NOT found (markup source): ", _sstm);
+ writeln("WARNING (io) src in NOT found (markup source): \n", _sstm, "or in", fn_src_in);
}
}
}
@@ -308,7 +311,7 @@ auto pod_zipMakeReady(M,P,S)(M doc_matters, P pths_pod, S _st) {
).filesystem_open_zpod.to!string;
_pth_mkup_src_in.copy(fn_src_out_filesystem); // check why here, thought dealt with elsewhere
}
- if (doc_matters.opt.action.pod) {
+ if (doc_matters.opt.action.source_or_pod) {
zip = podArchive("file_path_text", _pth_mkup_src_in, _pth_mkup_src_out, zip);
}
} else {
@@ -342,7 +345,7 @@ auto pod_zipMakeReady(M,P,S)(M doc_matters, P pths_pod, S _st) {
if (doc_matters.opt.action.source_or_pod) {
fn_src_in.copy(fn_src_out_filesystem);
}
- if (doc_matters.opt.action.pod) {
+ if (doc_matters.opt.action.source_or_pod) {
zip = podArchive("file_path_text", fn_src_in, fn_src_out_pod_zip_base, zip);
}
} else {
diff --git a/org/spine_info.org b/org/spine_info.org
index a2078fe..2d61c20 100644
--- a/org/spine_info.org
+++ b/org/spine_info.org
@@ -77,7 +77,7 @@
<<sisudoc_spine_README_command_examples_populate_db_text>>
-,*** generate a cgi search form in d
+,*** generate a cgi search form
<<sisudoc_spine_README_command_examples_search_db_cgi_text>>
@@ -85,7 +85,7 @@
<<sisudoc_spine_README_command_examples_compile_search_db_cgi_text>>
-,*** create db & search form
+,*** create db
<<sisudoc_spine_README_command_examples_create_db_and_search_form_text>>
@@ -196,7 +196,7 @@
<<sisudoc_spine_README_command_examples_compile_search_db_cgi_text>>
-### create db & search form
+### create db
<<sisudoc_spine_README_command_examples_create_db_and_search_form_text>>
@@ -624,23 +624,16 @@ for a document collection you can point to the document collection:
#+NAME: sisudoc_spine_README_command_examples_search_db_cgi_text
#+BEGIN_SRC text
-spine -v --cgi-search-form-codegen \
- --output=/var/www/html \
- ~spineMarkupSamples/pod
-
-spine -v --cgi-search-form-codegen --config=~spineMarkupSamples/pod
+The CGI search form is built separately in the sisudoc-spine-search-cgi/ directory.
-spine -v --cgi-search-form-codegen --config=~spineMarkupSamples/pod/.dr/config_local_site
+Steps:
+1. Clone the sisudoc-spine-search-cgi repository
+2. Configure views/configuration.txt with your web server settings
+3. Build the CGI binary using Nix or dub
+4. Deploy the CGI binary to your web server's cgi-bin directory
-spine --cgi-search-form-codegen --output=`echo ~webDocRoot` ~spineMarkupSamples/pod
-
-spine --cgi-search-form-codegen --cgi-sqlite-search-filename="spine_search" --output=`echo ~webDocRoot`
-
-spine -v --cgi-search-form-codegen \
- --sqlite-db-filename="spine.search.db" \
- --cgi-sqlite-search-filename="spine-search" \
- --output=/var/www/html \
- ~spineMarkupSamples/pod
+For detailed instructions, see:
+ sisudoc-spine-search-cgi/README.md
#+END_SRC
#+NAME: sisudoc_spine_README_command_examples_compile_search_db_cgi_text
@@ -676,9 +669,10 @@ cgi-bin directory
#+BEGIN_SRC text
spine -v \
--sqlite-db-create --sqlite-db-filename="spine.search.db" \
- --cgi-search-form-codegen --cgi-sqlite-search-filename="spine-search" \
--output=/var/www/html \
~spineMarkupSamples/pod/*
+
+Note: The CGI search form is built separately in sisudoc-spine-search-cgi/
#+END_SRC
#+NAME: sisudoc_spine_README_command_examples_html_with_links_to_search_form_text