@@ -18,7 +18,7 @@ name: Package and Upload Release Assets
1818env :
1919 PACKAGE_NAME : " cloud-sql-postgresql"
2020 FILES_TO_PACKAGE : " gemini-extension.json CLOUD-SQL-POSTGRESQL.md LICENSE"
21- GCS_BUCKET_URL : " https://storage.googleapis.com/genai-toolbox-extensions "
21+ GCS_BUCKET_URL : " https://storage.googleapis.com/genai-toolbox"
2222
2323on :
2424 release :
@@ -32,10 +32,10 @@ jobs:
3232 strategy :
3333 matrix :
3434 platform :
35- - { os: "linux", arch: "x64", download_path_segment: "linux/amd64", binary_suffix: "", archive_extension: "tar.gz", archive_command: 'tar -czvf "${ARCHIVE_NAME}" -C staging .' }
36- - { os: "darwin", arch: "arm64", download_path_segment: "darwin/arm64", binary_suffix: "", archive_extension: "tar.gz", archive_command: 'tar -czvf "${ARCHIVE_NAME}" -C staging .' }
37- - { os: "darwin", arch: "x64", download_path_segment: "darwin/amd64", binary_suffix: "", archive_extension: "tar.gz", archive_command: 'tar -czvf "${ARCHIVE_NAME}" -C staging .' }
38- - { os: "win32", arch: "x64", download_path_segment: "windows/amd64", binary_suffix: ".exe", archive_extension: "zip", archive_command: '(cd staging && zip ../"${ARCHIVE_NAME}" *)' }
35+ - { os: "linux", arch: "x64", download_path_segment: "linux/amd64/toolbox-extensions ", binary_suffix: "", archive_extension: "tar.gz", archive_command: 'tar -czvf "${ARCHIVE_NAME}" -C staging .' }
36+ - { os: "darwin", arch: "arm64", download_path_segment: "darwin/arm64/toolbox-extensions ", binary_suffix: "", archive_extension: "tar.gz", archive_command: 'tar -czvf "${ARCHIVE_NAME}" -C staging .' }
37+ - { os: "darwin", arch: "x64", download_path_segment: "darwin/amd64/toolbox-extensions ", binary_suffix: "", archive_extension: "tar.gz", archive_command: 'tar -czvf "${ARCHIVE_NAME}" -C staging .' }
38+ - { os: "win32", arch: "x64", download_path_segment: "windows/amd64/toolbox-extensions.exe ", binary_suffix: ".exe", archive_extension: "zip", archive_command: '(cd staging && zip ../"${ARCHIVE_NAME}" *)' }
3939
4040 steps :
4141 - name : Checkout code at the new tag
4747 id : vars
4848 run : |
4949 echo "archive_name=${{ matrix.platform.os }}.${{ matrix.platform.arch }}.${{ env.PACKAGE_NAME }}.${{ matrix.platform.archive_extension }}" >> $GITHUB_OUTPUT
50- echo "source_binary =toolbox${{ matrix.platform.binary_suffix }}" >> $GITHUB_OUTPUT
50+ echo "target_binary =toolbox${{ matrix.platform.binary_suffix }}" >> $GITHUB_OUTPUT
5151
5252 - name : Get Toolbox Version
5353 id : get_toolbox_version
@@ -60,12 +60,11 @@ jobs:
6060 env :
6161 TOOLBOX_VERSION : ${{ steps.get_toolbox_version.outputs.TOOLBOX_VERSION }}
6262 DOWNLOAD_PATH_SEGMENT : ${{ matrix.platform.download_path_segment }}
63- SOURCE_BINARY : ${{ steps.vars.outputs.source_binary }}
6463 run : |
65- DOWNLOAD_URL="${GCS_BUCKET_URL}/v${TOOLBOX_VERSION}/${DOWNLOAD_PATH_SEGMENT}/${SOURCE_BINARY} "
64+ DOWNLOAD_URL="${GCS_BUCKET_URL}/v${TOOLBOX_VERSION}/${DOWNLOAD_PATH_SEGMENT}"
6665
6766 echo "Downloading binary from: ${DOWNLOAD_URL}"
68- curl -L --fail -o "${SOURCE_BINARY }" "${DOWNLOAD_URL}"
67+ curl -L --fail -o "${target_binary }" "${DOWNLOAD_URL}"
6968
7069 echo "Binary downloaded and prepared."
7170 ls -l
@@ -75,15 +74,15 @@ jobs:
7574 env :
7675 ARCHIVE_COMMAND : ${{ matrix.platform.archive_command }}
7776 ARCHIVE_NAME : ${{ steps.vars.outputs.archive_name }}
78- SOURCE_BINARY : ${{ steps.vars.outputs.source_binary }}
77+ target_binary : ${{ steps.vars.outputs.target_binary }}
7978 run : |
8079 ARCHIVE_NAME="${{ matrix.platform.os }}.${{ matrix.platform.arch }}.${PACKAGE_NAME}.${{ matrix.platform.archive_extension }}"
81- SOURCE_BINARY ="toolbox${{ matrix.platform.binary_suffix }}"
80+ target_binary ="toolbox${{ matrix.platform.binary_suffix }}"
8281
83- echo "Packaging ${SOURCE_BINARY } into ${ARCHIVE_NAME}"
82+ echo "Packaging ${target_binary } into ${ARCHIVE_NAME}"
8483
8584 mkdir staging
86- cp "${SOURCE_BINARY }" "staging/${SOURCE_BINARY }"
85+ cp "${target_binary }" "staging/${target_binary }"
8786 cp ${FILES_TO_PACKAGE} staging/
8887
8988 if [[ "${{ matrix.platform.os }}" == "win32" ]]; then
0 commit comments