Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change official builds to use platform-specific VSIXs #4852

Merged
merged 1 commit into from
Oct 28, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ jobs:
- name: Compile
run: npm run compile

- name: Build extension package
run: gulp 'vsix:release:package'
- name: Build platform-neutral extension package
run: gulp 'vsix:release:package:platform-neutral'

- name: Run unit and integration tests
run: |
Expand All @@ -45,3 +45,6 @@ jobs:
env:
CODE_VERSION: 1.45.0
DISPLAY: :99.0

- name: Build platform-specific extension package
run: gulp 'vsix:release:package:platform-specific'
63 changes: 59 additions & 4 deletions .github/workflows/release-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,21 +22,76 @@ jobs:
npm i -g gulp

- name: Build extension package
run: gulp 'vsix:release:package'
run: gulp 'vsix:release:package:platform-specific'

- name: Run release tests
run: npm run test:release

- name: Get package version
run: node -e "console.log('VERSION=' + require('./package.json').version)" >> $GITHUB_ENV

- name: Upload release build
- name: Upload release build (darwin-arm64)
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./csharp-${{ env.VERSION }}.vsix
asset_name: csharp-${{ env.VERSION }}.vsix
asset_path: ./csharp-${{ env.VERSION }}-(darwin-arm64).vsix
asset_name: csharp-${{ env.VERSION }}-(darwin-arm64).vsix
asset_content_type: application/zip

- name: Upload release build (darwin-x64)
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./csharp-${{ env.VERSION }}-(darwin-x64).vsix
asset_name: csharp-${{ env.VERSION }}-(darwin-x64).vsix
asset_content_type: application/zip

- name: Upload release build (linux-x64)
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./csharp-${{ env.VERSION }}-(linux-x64).vsix
asset_name: csharp-${{ env.VERSION }}-(linux-x64).vsix
asset_content_type: application/zip

- name: Upload release build (win32-arm64)
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./csharp-${{ env.VERSION }}-(win32-arm64).vsix
asset_name: csharp-${{ env.VERSION }}-(win32-arm64).vsix
asset_content_type: application/zip

- name: Upload release build (win32-ia32)
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./csharp-${{ env.VERSION }}-(win32-ia32).vsix
asset_name: csharp-${{ env.VERSION }}-(win32-ia32).vsix
asset_content_type: application/zip

- name: Upload release build (win32-x64)
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./csharp-${{ env.VERSION }}-(win32-x64).vsix
asset_name: csharp-${{ env.VERSION }}-(win32-x64).vsix
asset_content_type: application/zip
3 changes: 2 additions & 1 deletion tasks/backcompatTasks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@

import * as gulp from 'gulp';

gulp.task('package:offline', gulp.series('vsix:offline:package'));
gulp.task('package:offline', gulp.series('vsix:release:package:platform-specific'));
gulp.task('vsix:offline:package', gulp.series('vsix:release:package:platform-specific'));
2 changes: 1 addition & 1 deletion tasks/offlinePackagingTasks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export function getPackageName(packageJSON: any, vscodePlatformId: string) {
return `${name}.${version}-${vscodePlatformId}.vsix`;
}

gulp.task('vsix:offline:package', async () => {
gulp.task('vsix:release:package:platform-specific', async () => {

if (process.platform === 'win32') {
throw new Error('Do not build offline packages on windows. Runtime executables will not be marked executable in *nix packages.');
Expand Down
2 changes: 1 addition & 1 deletion tasks/onlinePackagingTasks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ gulp.task('vsix:release:unpackage', () => {
return fs.createReadStream(packageName).pipe(Extract({ path: unpackedVsixPath }));
});

gulp.task('vsix:release:package', async (onError) => {
gulp.task('vsix:release:package:platform-neutral', async (onError) => {
del.sync(vscodeignorePath);

fs.copyFileSync(onlineVscodeignorePath, vscodeignorePath);
Expand Down