diff options
author | Munyoki Kilyungi | 2024-02-14 09:01:17 +0300 |
---|---|---|
committer | Munyoki Kilyungi | 2024-02-14 09:01:17 +0300 |
commit | 7353f9dac336c6ef4dbe30aa4de8c2053d605997 (patch) | |
tree | 619decf1a963879b9c991b1df6ffbd32cd76f369 /examples | |
parent | 36d778e4437e73b233c74af2e04c6f122ae44d09 (diff) | |
download | gn-transform-databases-7353f9dac336c6ef4dbe30aa4de8c2053d605997.tar.gz |
Capitalize the first string of every path.
This is done to match the RDF identifier.
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
Diffstat (limited to 'examples')
-rwxr-xr-x | examples/dataset-metadata-git.scm | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/examples/dataset-metadata-git.scm b/examples/dataset-metadata-git.scm index aa50476..023e4c6 100755 --- a/examples/dataset-metadata-git.scm +++ b/examples/dataset-metadata-git.scm @@ -5,7 +5,7 @@ (ice-9 getopt-long) (srfi srfi-26) ((ice-9 regex) #:select (regexp-substitute/global)) - ((transform strings) #:select (string-blank?)) + ((transform strings) #:select (string-blank? string-capitalize-first)) ((transform sql) #:select (call-with-target-database sql-for-each))) (define (save-file file result) @@ -25,10 +25,11 @@ str)) get)) (identifier - (regexp-substitute/global - #f "[^A-Za-z0-9:]" - (get "InfoPageName") - 'pre "_" 'post)) + (string-capitalize-first + (regexp-substitute/global + #f "[^A-Za-z0-9:]" + (get "InfoPageName") + 'pre "_" 'post))) (dir-name (string-append "/export/data/genenetwork/gn-docs/general/datasets/")) (file-name (cut string-append dir-name <>)) (summary (get* "Summary")) |