From abe7e7688d045982a28cfb22b8f6269269dd6cf5 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Tue, 5 Oct 2021 12:55:42 -0400 Subject: sqlite related internal naming --- org/config_nix.org | 59 ++++++++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 53 insertions(+), 6 deletions(-) (limited to 'org/config_nix.org') diff --git a/org/config_nix.org b/org/config_nix.org index ab01b55..cbd5ba6 100644 --- a/org/config_nix.org +++ b/org/config_nix.org @@ -153,6 +153,7 @@ export SpineDOC=<> export SpinePOD=$SpineDOC/markup/pod export SpineOUTversioned=<> export SpineOUT=<> +export SpineDBpath=<> echo '-*- mode: org -*- @@ -313,8 +314,8 @@ $SpineBIN/spine -v --html --html-link-search --html-link-curate --curate --outp ,*** create or re-create sql db (--sqlite-db-create or --sqlite-db-recreate) ,#+BEGIN_SRC sh -$SpineBIN/spine -v --sqlite-db-create --sqlite-db-filename="<>" --output="$SpineOUT/" -$SpineBIN/spine -v --sqlite-db-recreate --sqlite-db-filename="<>" --output="$SpineOUT/" +$SpineBIN/spine -v --sqlite-db-create --sqlite-db-filename="<>" --sqlite-db-path="$SpineDBpath" +$SpineBIN/spine -v --sqlite-db-recreate --sqlite-db-filename="<>" --sqlite-db-path="$SpineDBpath" ,#+END_SRC ,*** populate sqlite db @@ -326,7 +327,44 @@ $SpineBIN/spine -v --sqlite-update --sqlite-db-filename="<>" -- ,*** generate html (linked to search form), sql output, curate COMPOSITE ,#+BEGIN_SRC sh -$SpineBIN/spine -v --html --html-link-search --html-link-curate --curate --sqlite-update --sqlite-db-filename="<>" --cgi-sqlite-search-filename="<>" --output="$SpineOUT" $SpinePOD/* +$SpineBIN/spine -v --html --html-link-search --html-link-curate --curate --sqlite-update --sqlite-db-filename="<>" --cgi-sqlite-search-filename="<>" --sqlite-db-path="$SpineDBpath" --output="$SpineOUT" $SpinePOD/* +,#+END_SRC + +,*** generate html (linked to search form), sql output, curate COMPOSITE with resource configuration + +if names and paths are configured in resource configuration file, e.g. $SpinePOD/.rc/config_local_site + +,#+BEGIN_SRC sh +$SpineBIN/spine -v --html --html-link-search --html-link-curate --curate --sqlite-update $SpinePOD/* +,#+END_SRC + +,#+BEGIN_SRC yaml +# sample resource configuration file ( $SpinePOD/.rc/config_local_site ) +output: + path: "/srv/www/spine" +default: + language: "en" + papersize: "a4" + text_wrap: "80" + digest: "sha256" +webserv: + http: "http" + domain: "localhost" + data_http: "http" + data_domain: "localhost" + data_root_url: "https://sisudoc.org" + data_root_path: "/srv/www/spine" + images_root_part: "image" + cgi_title: "≅ SiSU Spine search" + cgi_http: "https" + cgi_domain: "sisudoc.org" + cgi_bin_url: "http://sisudoc.org/cgi-bin" + cgi_bin_part: "cgi-bin" + cgi_bin_path: "/var/www/cgi/cgi-bin" + cgi_search_script: "<>" + cgi_action: "https://sisudoc.org/spine_search" + db_sqlite_filename: "<>" + db_sqlite_path: "/var/www/sqlite" ,#+END_SRC ,*** make search form @@ -896,6 +934,7 @@ export SpineDOC=<> export SpinePOD=$SpineDOC/markup/pod #export SpineOUTversioned=<> export SpineOUT=<> +export SpineDBpath=<> export SpineCgiBIN=<> echo '-*- mode: org -*- @@ -974,7 +1013,7 @@ $SpineBIN/spine -v --html --html-link-search --html-link-curate --sqlite-db-file ,*** generate sql output ,#+BEGIN_SRC sh -SpineBIN/spine -v --sqlite-update --sqlite-db-filename="<>" --output=$SpineOUT $SpinePOD/* +SpineBIN/spine -v --sqlite-update --sqlite-db-filename="<>" --sqlite-db-path="$SpineDBpath" ,#+END_SRC ,*** generate curate @@ -987,13 +1026,15 @@ $SpineBIN/spine -v --html --html-link-curate --curate --output=$SpineOUT $Spine ,*** create or re-create sql db (--sqlite-db-create or --sqlite-db-recreate) ,#+BEGIN_SRC sh -$SpineBIN/spine -v --sqlite-db-recreate --sqlite-db-filename="<>" --output="$SpineOUT" +$SpineBIN/spine -v --sqlite-db-recreate --sqlite-db-filename="<>" --sqlite-db-path="$SpineDBpath" ,#+END_SRC ,*** generate html (linked to search form), sql output, curate ,#+BEGIN_SRC sh -$SpineBIN/spine -v --html --html-link-search --html-link-curate --curate --sqlite-db-filename="<>" --cgi-sqlite-search-filename="<>" --sqlite-update --output=$SpineOUT $SpinePOD/* +$SpineBIN/spine -v --html --html-link-search --html-link-curate --curate --sqlite-db-filename="<>" --cgi-sqlite-search-filename="<>" --sqlite-update --sqlite-db-path="$SpineDBpath" --output="$SpineOUT" $SpinePOD/* +#if names and paths are configured in resource configuration file, e.g. $SpinePOD/.rc/config_local_site +$SpineBIN/spine -v --html --html-link-search --html-link-curate --curate --sqlite-update $SpinePOD/* ,#+END_SRC ,*** make search form @@ -1272,6 +1313,12 @@ nixpkgs=<> /var/www #+END_SRC + +#+NAME: project_path_sqlite +#+BEGIN_SRC nix +/var/www/sqlite +#+END_SRC + #+NAME: nixpkgs_url #+BEGIN_SRC nix github:nixos/nixpkgs -- cgit v1.2.3