diff --git a/.github/scripts/gen-vscode-link-bullet.sh b/.github/scripts/gen-vscode-link-bullet.sh index 225a2c4526..fca0be8a9b 100755 --- a/.github/scripts/gen-vscode-link-bullet.sh +++ b/.github/scripts/gen-vscode-link-bullet.sh @@ -1,8 +1,9 @@ id=$1 label=$2 download_url_root=$3 +version=$4 -vsix_file=`aws s3 ls s3://$AWS_S3_BUCKET/snapshot/vscode-extensions/$id/ | awk '{$1=$2=$3=""; print $0}' | awk '{$1=$1};1' | grep "\.vsix$"` +vsix_file=`aws s3 ls s3://$AWS_S3_BUCKET/snapshot/vscode-extensions/$id/ | awk '{$1=$2=$3=""; print $0}' | awk '{$1=$1};1' | grep "${id}-${version}.*\.vsix$"` if [ ! -z "${vsix_file}" ]; then echo "
  • ${label}: ${vsix_file}
  • " fi \ No newline at end of file diff --git a/.github/workflows/build-vscode-extension.yml b/.github/workflows/build-vscode-extension.yml index ccc8338bbb..89e8d79dd1 100644 --- a/.github/workflows/build-vscode-extension.yml +++ b/.github/workflows/build-vscode-extension.yml @@ -55,7 +55,7 @@ jobs: echo "VSIX file to upload ${vsix_file}" s3_path=${{ inputs.dist }}/vscode-extensions/${{ inputs.extension-name }}/$base_version echo "S3 path: ${s3_path}" - aws s3 rm s3://$AWS_S3_BUCKET/$s3_path/ --recursive + aws s3 rm s3://$AWS_S3_BUCKET/$s3_path/ --recursive --exclude "*" --include "${{ inputs.extension-name }}-${base_version}*.vsix" aws s3 cp ./vsix/$vsix_file s3://$AWS_S3_BUCKET/$s3_path/$vsix_file --no-progress echo "version=$base_version" >> $GITHUB_OUTPUT echo "s3_url=${DOWNLOAD_URL_ROOT}/$s3_path/$vsix_file" >> $GITHUB_OUTPUT diff --git a/.github/workflows/release-vscode-extension.yml b/.github/workflows/release-vscode-extension.yml index 7fdd655c64..e5b71c29a7 100644 --- a/.github/workflows/release-vscode-extension.yml +++ b/.github/workflows/release-vscode-extension.yml @@ -74,7 +74,7 @@ jobs: echo "VSIX file to upload ${vsix_file}" s3_path=release/vscode-extensions/${{ inputs.extension-name }}/${{ steps.version.outputs.version }} echo "S3 path: ${s3_path}" - aws s3 rm s3://$AWS_S3_BUCKET/$s3_path/ --recursive + aws s3 rm s3://$AWS_S3_BUCKET/$s3_path/ --recursive --exclude "*" --include "${{ inputs.extension-name }}-${{ steps.version.outputs.version }}*.vsix" aws s3 cp ./vsix/$vsix_file s3://$AWS_S3_BUCKET/$s3_path/${{ steps.version.outputs.release_name }}.vsix --no-progress --checksum-algorithm CRC32 echo "s3_url=${DOWNLOAD_URL_ROOT}/$s3_path/${{ steps.version.outputs.release_name }}.vsix" >> $GITHUB_OUTPUT # - id: tools-team-slack diff --git a/.github/workflows/snapshot-vscode-extension.yml b/.github/workflows/snapshot-vscode-extension.yml index f1aafc845c..ff04939de5 100644 --- a/.github/workflows/snapshot-vscode-extension.yml +++ b/.github/workflows/snapshot-vscode-extension.yml @@ -37,6 +37,14 @@ jobs: - uses: actions/setup-node@v4 with: node-version: 22 + - name: version + id: version + run: | + cd ${{ github.workspace }}/vscode-extensions/${{ inputs.extension-name }} + version=$(npm pkg get version) + cd ${{ github.workspace }} + echo $version + echo "version=$version" >> $GITHUB_OUTPUT - name: Build .VSIX file id: build-vsix env: @@ -51,17 +59,17 @@ jobs: echo "VSIX file to upload ${vsix_file}" s3_path=snapshot/vscode-extensions/${{ inputs.extension-name }} echo "S3 path: ${s3_path}" - aws s3 rm s3://$AWS_S3_BUCKET/$s3_path/ --recursive + aws s3 rm s3://$AWS_S3_BUCKET/$s3_path/ --recursive --exclude "*" --include "${{ inputs.extension-name }}-${{ steps.version.outputs.version }}*.vsix" aws s3 cp ./vsix/$vsix_file s3://$AWS_S3_BUCKET/$s3_path/$vsix_file --no-progress --checksum-algorithm CRC32 - name: Update Nightly Builds download page run: | downloads_html="vscode-extensions-snippet.html" echo '' >> $downloads_html cat ./$downloads_html aws s3 mv ./$downloads_html s3://$AWS_S3_BUCKET/snapshot/vscode-extensions/ --no-progress --checksum-algorithm CRC32