From edbaf1e3ea1f459262ef5a86143e4c447a2d6279 Mon Sep 17 00:00:00 2001 From: shadow <81448108+shdwmtr@users.noreply.github.com> Date: Tue, 10 Dec 2024 00:57:56 -0400 Subject: [PATCH] fix: Fix CI --- .github/workflows/ci.yml | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9b35e4a..1d1a12b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -46,6 +46,10 @@ jobs: cp README.md ../../dist/"$d"README.md || echo "Failed to move README.md to dist" cp README ../../dist/"$d"README || echo "Failed to move README to dist" + echo "{\"commit\": \"$(git rev-parse HEAD)\", \"id\": \"$(git rev-list --max-parents=0 HEAD)\"}" > metadata.json + cp metadata.json ../../dist/"$d"metadata.json || echo "Failed to move metadata.json to dist" + + # Get the backend folder from plugin.json and move it to dist backend=$(jq -r '.backend' plugin.json) if [ "$backend" != "null" ]; then @@ -74,15 +78,6 @@ jobs: # get theme name theme_name=$(jq -r '.name' "$folder"plugin.json) - touch "$folder"metadata.json - - cd "$folder" - - # write current commit id to metadata.json - echo "{\"commit\": \"$(git rev-parse HEAD)\", \"id\": \"$(git rev-list --max-parents=0 HEAD)\"}" > metadata.json - - cd - - echo "Zipping folder: $folder" zip -r "$out.zip" "$folder" || echo "Failed to zip $folder" mv "$out.zip" ../build/$theme_name.zip || echo "Failed to move $folder.zip to build"