From 38a63df771523c6b834e67410834e6539bcc0e8d Mon Sep 17 00:00:00 2001 From: Clifton Palmer Date: Sat, 22 Mar 2025 06:26:31 -0500 Subject: [PATCH] Get project name based on current directory --- update-godot-builder.sh | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/update-godot-builder.sh b/update-godot-builder.sh index d85754c..86d62cc 100755 --- a/update-godot-builder.sh +++ b/update-godot-builder.sh @@ -24,10 +24,11 @@ then fi # --- Upon branch update, build gitweb snapshot URI -# TODO: get project name based on current directory name -project_name=wolf-seeking-sheep -snapshot_uri=https://git.purplebirdman.com/${project_name}.git/snapshot/${newrev}.tar.gz -echo "Snapshot URI - https://git.purplebirdman.com/${project_name}.git/snapshot/${newrev}.tar.gz" +git_project_name=$(pwd | grep -o '[a-zA-Z0-9-]*\.git') +echo "Git project name - $git_project_name" + +snapshot_uri=https://git.purplebirdman.com/${git_project_name}/snapshot/${newrev}.tar.gz +echo "Snapshot URI - $snapshot_uri" # --- Now send request to builder service godot_builder_uri=https://godot.purplebirdman.com/hook/make-build-request.lua -- 2.47.2