diff --git a/.github/workflows/build-portable-release-cuda.yml b/.github/workflows/build-portable-release-cuda.yml index 7ba1fc6b..571cbac0 100644 --- a/.github/workflows/build-portable-release-cuda.yml +++ b/.github/workflows/build-portable-release-cuda.yml @@ -160,31 +160,16 @@ jobs: rm requirements_cuda_temp.txt fi - # 6. Move up and rename folder to include version + # 6. Create ZIP file cd .. VERSION_CLEAN="${VERSION#v}" - if [[ "$RUNNER_OS" == "Windows" ]]; then - sleep 3 - powershell -Command "Move-Item -Path text-generation-webui -Destination text-generation-webui-${VERSION_CLEAN} -Force" - else - mv text-generation-webui text-generation-webui-${VERSION_CLEAN} - fi - - # 7. Create ZIP file ZIP_NAME="textgen-portable-${VERSION_CLEAN}-${PLATFORM}-cuda${CUDA_VERSION}.zip" echo "Creating archive: $ZIP_NAME" if [[ "$RUNNER_OS" == "Windows" ]]; then - powershell -Command "Compress-Archive -Path text-generation-webui-${VERSION_CLEAN} -DestinationPath $ZIP_NAME" + powershell -Command "Compress-Archive -Path text-generation-webui -DestinationPath $ZIP_NAME" else - zip -r "$ZIP_NAME" text-generation-webui-${VERSION_CLEAN} - fi - - # Rename back after creating the zip (the next step assumes this folder exists) - if [[ "$RUNNER_OS" == "Windows" ]]; then - powershell -Command "Move-Item -Path text-generation-webui-${VERSION_CLEAN} -Destination text-generation-webui -Force" - else - mv text-generation-webui-${VERSION_CLEAN} text-generation-webui + zip -r "$ZIP_NAME" text-generation-webui fi - name: Upload files to a GitHub release diff --git a/.github/workflows/build-portable-release-vulkan.yml b/.github/workflows/build-portable-release-vulkan.yml index c02aa662..4e88d4d9 100644 --- a/.github/workflows/build-portable-release-vulkan.yml +++ b/.github/workflows/build-portable-release-vulkan.yml @@ -146,31 +146,16 @@ jobs: echo "Installing Python packages from $REQ_FILE..." $PIP_PATH install --target="./$PACKAGES_PATH" -r "$REQ_FILE" - # 5. Move up and rename folder to include version + # 6. Create ZIP file cd .. VERSION_CLEAN="${VERSION#v}" - if [[ "$RUNNER_OS" == "Windows" ]]; then - sleep 3 - powershell -Command "Move-Item -Path text-generation-webui -Destination text-generation-webui-${VERSION_CLEAN} -Force" - else - mv text-generation-webui text-generation-webui-${VERSION_CLEAN} - fi - - # 6. Create ZIP file ZIP_NAME="textgen-portable-${VERSION_CLEAN}-${PLATFORM}-vulkan.zip" echo "Creating archive: $ZIP_NAME" if [[ "$RUNNER_OS" == "Windows" ]]; then - powershell -Command "Compress-Archive -Path text-generation-webui-${VERSION_CLEAN} -DestinationPath $ZIP_NAME" + powershell -Command "Compress-Archive -Path text-generation-webui -DestinationPath $ZIP_NAME" else - zip -r "$ZIP_NAME" text-generation-webui-${VERSION_CLEAN} - fi - - # Rename back after creating the zip (the next step assumes this folder exists) - if [[ "$RUNNER_OS" == "Windows" ]]; then - powershell -Command "Move-Item -Path text-generation-webui-${VERSION_CLEAN} -Destination text-generation-webui -Force" - else - mv text-generation-webui-${VERSION_CLEAN} text-generation-webui + zip -r "$ZIP_NAME" text-generation-webui fi - name: Upload files to a GitHub release diff --git a/.github/workflows/build-portable-release.yml b/.github/workflows/build-portable-release.yml index 85179617..6910ce2c 100644 --- a/.github/workflows/build-portable-release.yml +++ b/.github/workflows/build-portable-release.yml @@ -170,31 +170,16 @@ jobs: echo "Installing Python packages from $REQ_FILE..." $PIP_PATH install --target="./$PACKAGES_PATH" -r "$REQ_FILE" - # 5. Move up and rename folder to include version + # 5. Create ZIP file cd .. VERSION_CLEAN="${VERSION#v}" - if [[ "$RUNNER_OS" == "Windows" ]]; then - sleep 3 # Give time for any lingering file handles to close - powershell -Command "Move-Item -Path text-generation-webui -Destination text-generation-webui-${VERSION_CLEAN} -Force" - else - mv text-generation-webui text-generation-webui-${VERSION_CLEAN} - fi - - # 6. Create ZIP file ZIP_NAME="textgen-portable-${VERSION_CLEAN}-${PLATFORM}.zip" echo "Creating archive: $ZIP_NAME" if [[ "$RUNNER_OS" == "Windows" ]]; then - powershell -Command "Compress-Archive -Path text-generation-webui-${VERSION_CLEAN} -DestinationPath $ZIP_NAME" + powershell -Command "Compress-Archive -Path text-generation-webui -DestinationPath $ZIP_NAME" else - zip -r "$ZIP_NAME" text-generation-webui-${VERSION_CLEAN} - fi - - # Rename back after creating the zip (the next step assumes this folder exists) - if [[ "$RUNNER_OS" == "Windows" ]]; then - powershell -Command "Move-Item -Path text-generation-webui-${VERSION_CLEAN} -Destination text-generation-webui -Force" - else - mv text-generation-webui-${VERSION_CLEAN} text-generation-webui + zip -r "$ZIP_NAME" text-generation-webui fi - name: Upload files to a GitHub release