about summary refs log tree commit diff
diff options
context:
space:
mode:
authorMunyoki Kilyungi2025-05-10 10:31:47 +0300
committerMunyoki Kilyungi2025-05-10 10:31:47 +0300
commit502182210c786959a12a400dff3caf117cd1c88b (patch)
tree01337d6b11d11df021e7e5eaa028f393bcbf6966
parent3d3a44e8e3fcd9e8e074d711790b72f25e908a63 (diff)
downloadgn-machines-502182210c786959a12a400dff3caf117cd1c88b.tar.gz
Delete ttl files if they exist.
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
-rwxr-xr-xgenenetwork-local-container.sh5
1 files changed, 5 insertions, 0 deletions
diff --git a/genenetwork-local-container.sh b/genenetwork-local-container.sh
index d3555a5..57dd76e 100755
--- a/genenetwork-local-container.sh
+++ b/genenetwork-local-container.sh
@@ -417,6 +417,11 @@ init_rdf() {
     fi
     curr_dir="$PWD"
     cd "$BASE_DIR/gn-transform-databases"
+    if ls $BASE_DIR/var/lib/data/*ttl >/dev/null 2>&1; then
+	log INFO "Removing all the ttl files and generating them again"
+	rm $BASE_DIR/var/lib/data/*ttl
+    fi
+
     guix shell -m "manifest.scm" -- guile "generate-ttl-files.scm" \
 	 --settings "$curr_dir/etc/conn.scm" --output "$BASE_DIR/var/lib/data"
     guix shell guile-dbi -m "manifest.scm" -- guile load-rdf.scm \