Showing with 2,002 additions and 792 deletions.
  1. +179 −72 .github/workflows/insider-linux.yml
  2. +1 −1 .github/workflows/insider-macos.yml
  3. +11 −5 .github/workflows/insider-spearhead.yml
  4. +173 −72 .github/workflows/stable-linux.yml
  5. +1 −1 .github/workflows/stable-macos.yml
  6. +7 −4 .github/workflows/stable-spearhead.yml
  7. +2 −0 .gitignore
  8. +11 −8 build.sh
  9. +0 −24 build/azure-pipelines/computeYarnCacheKey.js
  10. +3 −0 build/build.sh
  11. +1 −1 check_cron_or_pr.sh
  12. +25 −15 check_tags.sh
  13. +1 −0 docs/extensions-compatibility.md
  14. +26 −8 docs/howto-build.md
  15. +2 −0 get_repo.sh
  16. +2 −2 insider.json
  17. +0 −11 install_remote_dependencies.sh
  18. +48 −0 package_linux_bin.sh
  19. +80 −0 package_linux_reh.sh
  20. +92 −92 patches/brand.patch
  21. +24 −33 patches/build-version.patch
  22. +24 −10 patches/fix-build-linux.patch
  23. +4 −4 patches/fix-eol-banner.patch
  24. +18 −5 patches/helper/settings.patch
  25. +20 −0 patches/linux/armhf/yarn-build.patch
  26. +10 −0 patches/linux/client/disable-remote.patch
  27. +23 −0 patches/linux/ppc64le/disable-sysroot.patch
  28. +20 −0 patches/linux/ppc64le/yarn-build.patch
  29. +75 −0 patches/linux/reh-node16.patch
  30. +42 −0 patches/linux/reh.patch.no
  31. +9 −0 patches/linux/rpm.patch
  32. +16 −0 patches/linux/use-node16.patch
  33. +14 −0 patches/linux/verify-glibc.patch
  34. +17 −0 patches/linux/yarn-dependencies.patch
  35. +39 −117 patches/ppc64le-support.patch
  36. +3 −3 patches/use-github-pat.patch
  37. +20 −8 prepare_assets.sh
  38. +35 −21 prepare_vscode.sh
  39. +25 −13 product.json
  40. +12 −0 src/insider/resources/linux/code-url-handler.desktop
  41. +18 −0 src/insider/resources/linux/code.appdata.xml
  42. +27 −0 src/insider/resources/linux/code.desktop
  43. +12 −0 src/stable/resources/linux/code-url-handler.desktop
  44. +18 −0 src/stable/resources/linux/code.appdata.xml
  45. +27 −0 src/stable/resources/linux/code.desktop
  46. +2 −2 stable.json
  47. +70 −0 stores/snapcraft/build.sh
  48. +23 −20 stores/snapcraft/check_version.sh
  49. +264 −0 stores/snapcraft/insider/electron-launch
  50. +0 −34 stores/snapcraft/insider/snap/local/bin/electron-launch
  51. +0 −86 stores/snapcraft/insider/snap/snapcraft.yaml
  52. +81 −0 stores/snapcraft/insider/snapcraft.yaml
  53. +264 −0 stores/snapcraft/stable/electron-launch
  54. +0 −34 stores/snapcraft/stable/snap/local/bin/electron-launch
  55. +0 −86 stores/snapcraft/stable/snap/snapcraft.yaml
  56. +81 −0 stores/snapcraft/stable/snapcraft.yaml
251 changes: 179 additions & 72 deletions .github/workflows/insider-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ on:
env:
APP_NAME: VSCodium
ASSETS_REPOSITORY: ${{ github.repository }}-insiders
BINARY_NAME: codium-insiders
DISABLE_UPDATE: 'yes'
GITHUB_BRANCH: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || 'insider' }}
OS_NAME: linux
VERSIONS_REPOSITORY: ${{ github.repository_owner }}/versions
Expand All @@ -31,8 +33,6 @@ env:
jobs:
check:
runs-on: ubuntu-latest
container:
image: vscodium/vscodium-linux-build-agent:bionic-x64
outputs:
MS_COMMIT: ${{ env.MS_COMMIT }}
MS_TAG: ${{ env.MS_TAG }}
Expand All @@ -41,132 +41,148 @@ jobs:
SHOULD_DEPLOY: ${{ env.SHOULD_DEPLOY }}

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
ref: ${{ env.GITHUB_BRANCH }}

- name: Clone VSCode repo
env:
RELEASE_VERSION: ${{ github.event.inputs.release_version }}
PULL_REQUEST_ID: ${{ github.event.inputs.checkout_pr }}
run: ./get_repo.sh

- name: Check PR or cron
env:
GENERATE_ASSETS: ${{ github.event.inputs.generate_assets }}
run: ./check_cron_or_pr.sh

dependencies:
- name: Check existing VSCodium tags/releases
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: ./check_tags.sh

compile:
needs:
- check
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
env:
MS_COMMIT: ${{ needs.check.outputs.MS_COMMIT }}
MS_TAG: ${{ needs.check.outputs.MS_TAG }}
RELEASE_VERSION: ${{ needs.check.outputs.RELEASE_VERSION }}
strategy:
fail-fast: false
matrix:
include:
- vscode_arch: x64
image: vscodium/vscodium-linux-build-agent:centos7-devtoolset8-x64
# - vscode_arch: arm64
# image: vscodium/vscodium-linux-build-agent:centos7-devtoolset8-arm64
container:
image: ${{ matrix.image }}
if: needs.check.outputs.SHOULD_BUILD == 'yes' || needs.check.outputs.SHOULD_DEPLOY == 'yes'
SHOULD_BUILD: 'yes'
VSCODE_ARCH: 'x64'
outputs:
BUILD_SOURCEVERSION: ${{ env.BUILD_SOURCEVERSION }}
if: needs.check.outputs.SHOULD_BUILD == 'yes' || github.event.inputs.generate_assets == 'true'

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
ref: ${{ env.GITHUB_BRANCH }}

- name: Setup Node.js environment
uses: actions/setup-node@v4
with:
node-version: '18.17'

- name: Install Yarn
run: npm install -g yarn

- name: Setup Python 3
uses: actions/setup-python@v5
with:
python-version: '3.11'

- name: Install libkrb5-dev
run: sudo apt-get install -y libkrb5-dev

- name: Clone VSCode repo
run: ./get_repo.sh

- uses: docker/setup-qemu-action@v3
if: matrix.vscode_arch == 'arm64' || matrix.vscode_arch == 'ppc64le'
- name: Build
run: ./build.sh

- name: Install remote dependencies
run: ./install_remote_dependencies.sh
- name: Compress vscode artifact
run: |
tar -cz --exclude='.build/node' --exclude='**/node_modules' -f vscode.tar.gz vscode
- name: Save remote dependencies
- name: Upload vscode artifact
uses: actions/upload-artifact@v3
with:
name: remote-dependencies-${{ matrix.vscode_arch }}
path: ./remote-dependencies.tar
name: vscode
path: ./vscode.tar.gz
retention-days: ${{ needs.check.outputs.SHOULD_DEPLOY == 'yes' && 30 || 1 }}

build:
needs:
- check
- dependencies
- compile
runs-on: ubuntu-latest
env:
DISABLE_UPDATE: 'yes'
MS_COMMIT: ${{ needs.check.outputs.MS_COMMIT }}
MS_TAG: ${{ needs.check.outputs.MS_TAG }}
RELEASE_VERSION: ${{ needs.check.outputs.RELEASE_VERSION }}
SHOULD_BUILD: ${{ needs.check.outputs.SHOULD_BUILD }}
SHOULD_DEPLOY: ${{ needs.check.outputs.SHOULD_DEPLOY }}
strategy:
fail-fast: false
matrix:
include:
- vscode_arch: x64
npm_arch: x64
image: vscodium/vscodium-linux-build-agent:focal-x64
image: vscodium/vscodium-linux-build-agent:bionic-x64
- vscode_arch: arm64
npm_arch: arm64
image: vscodium/vscodium-linux-build-agent:focal-arm64
image: vscodium/vscodium-linux-build-agent:bionic-arm64
- vscode_arch: armhf
npm_arch: arm
image: vscodium/vscodium-linux-build-agent:focal-armhf
- vscode_arch: ppc64le
npm_arch: ppc64
image: vscodium/vscodium-linux-build-agent:focal-ppc64le
image: vscodium/vscodium-linux-build-agent:bionic-armhf
container:
image: ${{ matrix.image }}
env:
VSCODE_ARCH: ${{ matrix.vscode_arch }}
env:
BUILD_SOURCEVERSION: ${{ needs.compile.outputs.BUILD_SOURCEVERSION }}
MS_COMMIT: ${{ needs.check.outputs.MS_COMMIT }}
MS_TAG: ${{ needs.check.outputs.MS_TAG }}
RELEASE_VERSION: ${{ needs.check.outputs.RELEASE_VERSION }}
SHOULD_BUILD: ${{ needs.check.outputs.SHOULD_BUILD }}
SHOULD_DEPLOY: ${{ needs.check.outputs.SHOULD_DEPLOY }}
VSCODE_ARCH: ${{ matrix.vscode_arch }}
outputs:
RELEASE_VERSION: ${{ env.RELEASE_VERSION }}
SHOULD_BUILD: ${{ env.SHOULD_BUILD }}
SHOULD_DEPLOY: ${{ env.SHOULD_DEPLOY }}
if: needs.check.outputs.SHOULD_BUILD == 'yes' || needs.check.outputs.SHOULD_DEPLOY == 'yes'
if: needs.check.outputs.SHOULD_BUILD == 'yes' || github.event.inputs.generate_assets == 'true'

steps:
- uses: actions/checkout@v3
with:
ref: ${{ env.GITHUB_BRANCH }}

- name: Clone VSCode repo
run: ./get_repo.sh

- name: Install GH
run: ./install_gh.sh
if: env.SHOULD_DEPLOY == 'yes'

- name: Check existing VSCodium tags/releases
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CHECK_REH: 'no'
run: ./check_tags.sh
if: env.SHOULD_DEPLOY == 'yes'

- name: Restore remote dependencies
- name: Install libkrb5-dev
run: sudo apt-get install -y libkrb5-dev
if: env.SHOULD_BUILD == 'yes' || github.event.inputs.generate_assets == 'true'

- name: Download vscode artifact
uses: actions/download-artifact@v3
with:
name: remote-dependencies-${{ matrix.vscode_arch }}
if: env.SHOULD_BUILD == 'yes' && matrix.vscode_arch == 'x64'
name: vscode
if: env.SHOULD_BUILD == 'yes' || github.event.inputs.generate_assets == 'true'

- name: Build
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
npm_config_arch: ${{ matrix.npm_arch }}
run: ./build.sh
if: env.SHOULD_BUILD == 'yes'
run: ./package_linux_bin.sh
if: env.SHOULD_BUILD == 'yes' || github.event.inputs.generate_assets == 'true'

- name: Prepare assets
env:
SHOULD_BUILD_REH: 'no'
run: ./prepare_assets.sh
if: env.SHOULD_BUILD == 'yes' && (env.SHOULD_DEPLOY == 'yes' || github.event.inputs.generate_assets == 'true')
if: (env.SHOULD_BUILD == 'yes' && env.SHOULD_DEPLOY == 'yes') || github.event.inputs.generate_assets == 'true'

- name: Release
env:
Expand All @@ -182,8 +198,86 @@ jobs:
run: ./update_version.sh
if: env.SHOULD_BUILD == 'yes' && env.SHOULD_DEPLOY == 'yes'

- name: Upload assets
uses: actions/upload-artifact@v3
with:
name: bin-${{ matrix.vscode_arch }}
path: assets/
retention-days: 3
if: env.SHOULD_DEPLOY == 'no' && github.event.inputs.generate_assets == 'true'

reh:
needs:
- check
- compile
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
include:
- vscode_arch: x64
npm_arch: x64
- vscode_arch: arm64
npm_arch: arm64
- vscode_arch: armhf
npm_arch: arm
# - vscode_arch: ppc64le
# npm_arch: ppc64
env:
BUILD_SOURCEVERSION: ${{ needs.compile.outputs.BUILD_SOURCEVERSION }}
MS_COMMIT: ${{ needs.check.outputs.MS_COMMIT }}
MS_TAG: ${{ needs.check.outputs.MS_TAG }}
RELEASE_VERSION: ${{ needs.check.outputs.RELEASE_VERSION }}
SHOULD_BUILD: ${{ needs.check.outputs.SHOULD_BUILD }}
SHOULD_DEPLOY: ${{ needs.check.outputs.SHOULD_DEPLOY }}
VSCODE_ARCH: ${{ matrix.vscode_arch }}
if: needs.check.outputs.SHOULD_BUILD == 'yes' || github.event.inputs.generate_assets == 'true'

steps:
- uses: actions/checkout@v3
with:
ref: ${{ env.GITHUB_BRANCH }}

- name: Install GH
run: ./install_gh.sh

- name: Check existing VSCodium tags/releases
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CHECK_ONLY_REH: 'yes'
run: ./check_tags.sh

- name: Download vscode artifact
uses: actions/download-artifact@v3
with:
name: vscode
if: env.SHOULD_BUILD_REH != 'no' || github.event.inputs.generate_assets == 'true'

- name: Build
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
npm_config_arch: ${{ matrix.npm_arch }}
run: ./package_linux_reh.sh
if: env.SHOULD_BUILD_REH != 'no' || github.event.inputs.generate_assets == 'true'

- name: Release
env:
GITHUB_TOKEN: ${{ secrets.STRONGER_GITHUB_TOKEN }}
GITHUB_USERNAME: ${{ github.repository_owner }}
run: ./release.sh
if: env.SHOULD_BUILD_REH != 'no' && env.SHOULD_DEPLOY == 'yes'

- name: Upload assets
uses: actions/upload-artifact@v3
with:
name: reh-${{ matrix.vscode_arch }}
path: assets/
retention-days: 3
if: env.SHOULD_DEPLOY == 'no' && github.event.inputs.generate_assets == 'true'

aur:
needs:
- check
- build
runs-on: ubuntu-latest
strategy:
Expand All @@ -192,12 +286,12 @@ jobs:
include:
- package_name: vscodium-insiders-bin
- package_name: vscodium-insiders
if: needs.build.outputs.SHOULD_DEPLOY == 'yes'
if: needs.check.outputs.SHOULD_DEPLOY == 'yes'

steps:
- name: Get version
env:
RELEASE_VERSION: ${{ needs.build.outputs.RELEASE_VERSION }}
RELEASE_VERSION: ${{ needs.check.outputs.RELEASE_VERSION }}
run: echo "PACKAGE_VERSION=${RELEASE_VERSION/-*/}" >> "${GITHUB_ENV}"

- name: Publish ${{ matrix.package_name }}
Expand All @@ -211,17 +305,18 @@ jobs:

snap:
needs:
- check
- build
runs-on: ubuntu-latest
env:
APP_NAME: codium
RELEASE_VERSION: ${{ needs.check.outputs.RELEASE_VERSION }}
strategy:
fail-fast: false
matrix:
platform:
- amd64
- arm64
# if: needs.build.outputs.SHOULD_DEPLOY == 'yes'
# if: needs.check.outputs.SHOULD_DEPLOY == 'yes'
if: false

steps:
Expand All @@ -236,25 +331,37 @@ jobs:
run: ./stores/snapcraft/check_version.sh

- uses: docker/setup-qemu-action@v3
if: env.SHOULD_DEPLOY == 'yes'
if: env.SHOULD_BUILD == 'yes'

- name: Prepare snapcraft.yaml
env:
ARCHITECTURE: ${{ matrix.platform }}
run: ./stores/snapcraft/build.sh
if: env.SHOULD_BUILD == 'yes'

# - uses: diddlesnaps/snapcraft-multiarch-action@v1
# with:
# path: stores/snapcraft/build
# architecture: ${{ matrix.platform }}
# id: build
# if: env.SHOULD_BUILD == 'yes'

- uses: diddlesnaps/snapcraft-multiarch-action@v1
- uses: snapcore/action-build@v1
with:
path: stores/snapcraft/insider
architecture: ${{ matrix.platform }}
path: stores/snapcraft/build
id: build
if: env.SHOULD_DEPLOY == 'yes'
if: env.SHOULD_BUILD == 'yes'

- uses: diddlesnaps/snapcraft-review-action@v1
with:
snap: ${{ steps.build.outputs.snap }}
isClassic: 'true'
if: env.SHOULD_DEPLOY == 'yes'
# - uses: diddlesnaps/snapcraft-review-action@v1
# with:
# snap: ${{ steps.build.outputs.snap }}
# isClassic: 'true'
# if: env.SHOULD_BUILD == 'yes'

- uses: snapcore/action-publish@master
env:
SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAP_STORE_LOGIN }}
- uses: svenstaro/upload-release-action@v2
with:
snap: ${{ steps.build.outputs.snap }}
release: edge
if: env.SHOULD_DEPLOY == 'yes'
repo_name: ${{ env.ASSETS_REPOSITORY }}
repo_token: ${{ secrets.STRONGER_GITHUB_TOKEN }}
file: ${{ steps.build.outputs.snap }}
tag: ${{ env.RELEASE_VERSION }}
if: env.SHOULD_DEPLOY_TO_RELEASE == 'yes'