removed unnecessary files/folders
This commit is contained in:
parent
5048b1ad4c
commit
52d5d0ec84
181
.github/workflows/build-for-pr.yml
vendored
181
.github/workflows/build-for-pr.yml
vendored
|
@ -1,181 +0,0 @@
|
|||
name: build-for-pr
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
types:
|
||||
- labeled
|
||||
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
|
||||
env:
|
||||
TERM: xterm
|
||||
|
||||
jobs:
|
||||
build-linux-for-pr:
|
||||
runs-on: ubuntu-22.04
|
||||
if: ${{ github.event.label.name == 'Build Apps for PR' }}
|
||||
steps:
|
||||
- name: ci/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ github.event.pull_request.head.sha }}
|
||||
- name: ci/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: ci/install-dependencies
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
wget -qO - https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_22.04/Release.key | sudo apt-key add -
|
||||
wget -qO /usr/local/bin/yq https://github.com/mikefarah/yq/releases/download/v4.20.1/yq_linux_amd64 && chmod a+x /usr/local/bin/yq
|
||||
sudo apt-get update || true && sudo apt-get install -y ca-certificates libxtst-dev libpng++-dev gcc-aarch64-linux-gnu g++-aarch64-linux-gnu jq icnsutils graphicsmagick tzdata
|
||||
npm ci
|
||||
- name: ci/build
|
||||
run: |
|
||||
mkdir -p ./build/linux
|
||||
npm run package:linux-tar
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/linux
|
||||
- name: ci/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-linux
|
||||
path: ./build/linux
|
||||
retention-days: 10 ## No need to keep CI builds more than 10 days
|
||||
|
||||
windows-install-deps:
|
||||
runs-on: windows-2022
|
||||
if: ${{ github.event.label.name == 'Build Apps for PR' }}
|
||||
steps:
|
||||
- name: ci/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ github.event.pull_request.head.sha }}
|
||||
- name: ci/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: ci/cache-node-modules
|
||||
id: cache-node-modules
|
||||
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
|
||||
with:
|
||||
path: node_modules
|
||||
key: ${{ runner.os }}-build-node-modules-${{ hashFiles('**/package-lock.json') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-build-node-modules
|
||||
${{ runner.os }}-build-
|
||||
${{ runner.os }}-
|
||||
- name: ci/install-dependencies
|
||||
if: steps.cache-node-modules.outputs.cache-hit != 'true'
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: npm ci --openssl_fips=''
|
||||
|
||||
build-win-for-pr:
|
||||
runs-on: windows-2022
|
||||
if: ${{ github.event.label.name == 'Build Apps for PR' }}
|
||||
needs:
|
||||
- windows-install-deps
|
||||
steps:
|
||||
- name: ci/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ github.event.pull_request.head.sha }}
|
||||
- name: ci/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: ci/cache-node-modules
|
||||
id: cache-node-modules
|
||||
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
|
||||
with:
|
||||
path: node_modules
|
||||
key: ${{ runner.os }}-build-node-modules-${{ hashFiles('package-lock.json') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-build-node-modules
|
||||
${{ runner.os }}-build-
|
||||
${{ runner.os }}-
|
||||
- name: ci/install-node-gyp
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
choco install yq --version 4.15.1 -y
|
||||
npm i -g node-gyp
|
||||
node-gyp install
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers"
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers" --arch arm64
|
||||
- name: ci/install-dependencies
|
||||
if: steps.cache-node-modules.outputs.cache-hit != 'true'
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
npm ci --openssl_fips=''
|
||||
- name: ci/build
|
||||
env:
|
||||
MM_WIN_INSTALLERS: 1
|
||||
PFX_KEY: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_PFX_KEY }}
|
||||
CSC_KEY_PASSWORD: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_CSC_KEY_PASSWORD }}
|
||||
PFX: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_PFX }}
|
||||
CSC_LINK: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_CSC_LINK }}
|
||||
run: |
|
||||
mkdir -p ./build/win
|
||||
npm run package:windows
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/win
|
||||
- name: ci/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-windows
|
||||
path: ./build/win
|
||||
retention-days: 10 ## No need to keep CI builds more than 10 days
|
||||
|
||||
build-mac-for-pr:
|
||||
runs-on: macos-12
|
||||
if: ${{ github.event.label.name == 'Build Apps for PR' }}
|
||||
steps:
|
||||
- name: ci/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ github.event.pull_request.head.sha }}
|
||||
- name: ci/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: ci/install-dependencies
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
brew install yq
|
||||
jq '.mac.target=["zip"]' electron-builder.json | jq '.mac.gatekeeperAssess=false' > /tmp/electron-builder.json && cp /tmp/electron-builder.json .
|
||||
npm ci
|
||||
- name: ci/build
|
||||
env:
|
||||
APPLE_ID: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_APPLE_ID }}
|
||||
APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_APPLE_ID_PASS }}
|
||||
CSC_FOR_PULL_REQUEST: true
|
||||
CSC_KEY_PASSWORD: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_CSC_KEY_PASSWORD }}
|
||||
CSC_LINK: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_CSC_LINK }}
|
||||
MAC_PROFILE: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_DMG_PROFILE }}
|
||||
run: |
|
||||
echo $MAC_PROFILE | base64 -D > ./mac.provisionprofile
|
||||
mkdir -p ./build/macos
|
||||
npm run package:mac
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/macos/
|
||||
- name: ci/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-macos
|
||||
path: ./build/macos/
|
||||
retention-days: 10 ## No need to keep CI builds more than 10 days
|
214
.github/workflows/ci.yaml
vendored
214
.github/workflows/ci.yaml
vendored
|
@ -1,214 +0,0 @@
|
|||
name: ci
|
||||
on:
|
||||
pull_request:
|
||||
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
|
||||
env:
|
||||
TERM: xterm
|
||||
|
||||
jobs:
|
||||
build-linux:
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- name: ci/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
- name: ci/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: ci/install-dependencies
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
wget -qO - https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_22.04/Release.key | sudo apt-key add -
|
||||
wget -qO /usr/local/bin/yq https://github.com/mikefarah/yq/releases/download/v4.20.1/yq_linux_amd64 && chmod a+x /usr/local/bin/yq
|
||||
sudo apt-get update || true && sudo apt-get install -y ca-certificates libxtst-dev libpng++-dev gcc-aarch64-linux-gnu g++-aarch64-linux-gnu jq icnsutils graphicsmagick tzdata
|
||||
npm ci
|
||||
- name: ci/test
|
||||
uses: ./.github/actions/test
|
||||
- name: ci/build
|
||||
run: |
|
||||
mkdir -p ./build/linux
|
||||
npm run package:linux-tar
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/linux
|
||||
- name: ci/upload-test-results
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: linux-test-results
|
||||
path: test-results.xml
|
||||
retention-days: 5
|
||||
- name: ci/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-linux
|
||||
path: ./build/linux
|
||||
retention-days: 10 ## No need to keep CI builds more than 10 days
|
||||
|
||||
windows-install-deps:
|
||||
runs-on: windows-2022
|
||||
steps:
|
||||
- name: ci/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
- name: ci/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: ci/cache-node-modules
|
||||
id: cache-node-modules
|
||||
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
|
||||
with:
|
||||
path: node_modules
|
||||
key: ${{ runner.os }}-build-node-modules-${{ hashFiles('**/package-lock.json') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-build-node-modules
|
||||
${{ runner.os }}-build-
|
||||
${{ runner.os }}-
|
||||
- name: ci/install-dependencies
|
||||
if: steps.cache-node-modules.outputs.cache-hit != 'true'
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
choco install yq --version 4.15.1 -y
|
||||
npm i -g node-gyp
|
||||
node-gyp install
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers"
|
||||
npm ci --openssl_fips=''
|
||||
|
||||
build-win-no-installer:
|
||||
runs-on: windows-2022
|
||||
needs:
|
||||
- windows-install-deps
|
||||
steps:
|
||||
- name: ci/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
- name: ci/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: ci/cache-node-modules
|
||||
id: cache-node-modules
|
||||
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
|
||||
with:
|
||||
path: node_modules
|
||||
key: ${{ runner.os }}-build-node-modules-${{ hashFiles('package-lock.json') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-build-node-modules
|
||||
${{ runner.os }}-build-
|
||||
${{ runner.os }}-
|
||||
- name: ci/install-node-gyp
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
choco install yq --version 4.15.1 -y
|
||||
npm i -g node-gyp
|
||||
node-gyp install
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers"
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers" --arch arm64
|
||||
- name: ci/install-dependencies
|
||||
if: steps.cache-node-modules.outputs.cache-hit != 'true'
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
npm ci --openssl_fips=''
|
||||
- name: ci/test
|
||||
uses: ./.github/actions/test
|
||||
- name: ci/build
|
||||
run: |
|
||||
mkdir -p ./build/win
|
||||
npm run package:windows
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/win
|
||||
- name: ci/upload-test-results
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: windows-test-results
|
||||
path: test-results.xml
|
||||
retention-days: 5
|
||||
- name: ci/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-windows
|
||||
path: ./build/win
|
||||
retention-days: 10 ## No need to keep CI builds more than 10 days
|
||||
|
||||
build-mac-no-dmg:
|
||||
runs-on: macos-12
|
||||
steps:
|
||||
- name: ci/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
- name: ci/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: ci/install-dependencies
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
brew install yq
|
||||
jq '.mac.target=["zip"]' electron-builder.json | jq '.mac.gatekeeperAssess=false' > /tmp/electron-builder.json && cp /tmp/electron-builder.json .
|
||||
npm ci
|
||||
- name: ci/test
|
||||
uses: ./.github/actions/test
|
||||
- name: ci/build
|
||||
run: |
|
||||
mkdir -p ./build/macos
|
||||
npm run package:mac
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/macos/
|
||||
- name: ci/upload-test-results
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: macos-test-results
|
||||
path: test-results.xml
|
||||
retention-days: 5
|
||||
- name: ci/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-macos
|
||||
path: ./build/macos/
|
||||
retention-days: 10 ## No need to keep CI builds more than 10 days
|
||||
|
||||
report-test-results:
|
||||
if: always()
|
||||
needs:
|
||||
- build-mac-no-dmg
|
||||
- build-win-no-installer
|
||||
- build-linux
|
||||
runs-on: ubuntu-22.04
|
||||
permissions:
|
||||
checks: write
|
||||
pull-requests: write
|
||||
steps:
|
||||
- name: ci/download-macos-test-results
|
||||
uses: actions/download-artifact@c850b930e6ba138125429b7e5c93fc707a7f8427 # v4.1.4
|
||||
with:
|
||||
name: macos-test-results
|
||||
path: macos-test-results
|
||||
- name: ci/download-windows-test-results
|
||||
uses: actions/download-artifact@c850b930e6ba138125429b7e5c93fc707a7f8427 # v4.1.4
|
||||
with:
|
||||
name: windows-test-results
|
||||
path: windows-test-results
|
||||
- name: ci/download-linux-test-results
|
||||
uses: actions/download-artifact@c850b930e6ba138125429b7e5c93fc707a7f8427 # v4.1.4
|
||||
with:
|
||||
name: linux-test-results
|
||||
path: linux-test-results
|
||||
- name: ci/publish-results
|
||||
uses: EnricoMi/publish-unit-test-result-action@a3caf02865c0604ad3dc1ecfcc5cdec9c41b7936 # v2.3.0
|
||||
with:
|
||||
comment_mode: failures
|
||||
compare_to_earlier_commit: false
|
||||
junit_files: "**/*.xml"
|
40
.github/workflows/codeql-analysis.yml
vendored
40
.github/workflows/codeql-analysis.yml
vendored
|
@ -1,40 +0,0 @@
|
|||
name: "CodeQL"
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [master]
|
||||
pull_request:
|
||||
# The branches below must be a subset of the branches above
|
||||
branches: [master]
|
||||
schedule:
|
||||
- cron: "0 0 * * 0"
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
analyze:
|
||||
permissions:
|
||||
security-events: write
|
||||
name: Analyze
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
language: ["javascript"]
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
|
||||
- name: Initialize CodeQL
|
||||
uses: github/codeql-action/init@423a04bb2cb7cd2643007122588f1387778f14d0 # v2.16.5
|
||||
with:
|
||||
languages: ${{ matrix.language }}
|
||||
config-file: ./.github/codeql/codeql-config.yml
|
||||
|
||||
# Autobuild attempts to build any compiled languages
|
||||
- name: Autobuild
|
||||
uses: github/codeql-action/autobuild@423a04bb2cb7cd2643007122588f1387778f14d0 # v2.16.5
|
||||
|
||||
- name: Perform CodeQL Analysis
|
||||
uses: github/codeql-action/analyze@423a04bb2cb7cd2643007122588f1387778f14d0 # v2.16.5
|
136
.github/workflows/compatibility-matrix-testing.yml
vendored
136
.github/workflows/compatibility-matrix-testing.yml
vendored
|
@ -1,136 +0,0 @@
|
|||
name: Compatibility Matrix Testing
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
CMT_MATRIX:
|
||||
description: "A JSON object representing the testing matrix"
|
||||
required: true
|
||||
type: string
|
||||
DESKTOP_VERSION:
|
||||
description: "The desktop version to test"
|
||||
required: true
|
||||
|
||||
jobs:
|
||||
## This is picked up after the finish for cleanup
|
||||
upload-cmt-server-detals:
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- name: cmt/generate-instance-details-file
|
||||
run: echo '${{ inputs.CMT_MATRIX }}' > instance-details.json
|
||||
|
||||
- name: cmt/upload-instance-details
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: instance-details.json
|
||||
path: instance-details.json
|
||||
retention-days: 1
|
||||
|
||||
calculate-commit-hash:
|
||||
runs-on: ubuntu-22.04
|
||||
outputs:
|
||||
DESKTOP_SHA: ${{ steps.repo.outputs.DESKTOP_SHA }}
|
||||
steps:
|
||||
- name: cmt/checkout-desktop
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ inputs.DESKTOP_VERSION }}
|
||||
|
||||
- name: cmt/calculate-mattermost-sha
|
||||
id: repo
|
||||
run: echo "DESKTOP_SHA=$(git rev-parse HEAD)" >> ${GITHUB_OUTPUT}
|
||||
|
||||
update-initial-status:
|
||||
runs-on: ubuntu-22.04
|
||||
needs:
|
||||
- calculate-commit-hash
|
||||
steps:
|
||||
- uses: mattermost/actions/delivery/update-commit-status@746563b58e737a17a8ceb00b84a813b9e6e1b236
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
repository_full_name: mattermost/desktop
|
||||
commit_sha: ${{ needs.calculate-commit-hash.outputs.DESKTOP_SHA }}
|
||||
context: e2e/compatibility-matrix-testing
|
||||
description: "Compatibility Matrix Testing for ${{ inputs.DESKTOP_VERSION }} version"
|
||||
status: pending
|
||||
|
||||
# Input follows the below schema
|
||||
# {
|
||||
# "environment": [
|
||||
# {
|
||||
# "os": "linux",
|
||||
# "runner": "ubuntu-22.04"
|
||||
# },
|
||||
# {
|
||||
# "os": "macos",
|
||||
# "runner": "macos-13"
|
||||
# },
|
||||
# {
|
||||
# "os": "windows",
|
||||
# "runner": "windows-2022"
|
||||
# }
|
||||
# ],
|
||||
# "server": [
|
||||
# {
|
||||
# "version": "9.6.1",
|
||||
# "url": "https://delivery-cmt-8467830017-9-6-1.test.mattermost.cloud/"
|
||||
# },
|
||||
# {
|
||||
# "version": "9.5.2",
|
||||
# "url": "https://delivery-cmt-8467830017-9-5-2.test.mattermost.cloud/"
|
||||
# }
|
||||
# ]
|
||||
# }
|
||||
e2e:
|
||||
name: ${{ matrix.environment.os }}-${{ matrix.server.version }}
|
||||
uses: ./.github/workflows/e2e-functional-template.yml
|
||||
needs:
|
||||
- update-initial-status
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix: ${{ fromJson(inputs.CMT_MATRIX) }}
|
||||
secrets: inherit
|
||||
with:
|
||||
runs-on: ${{ matrix.environment.runner }}
|
||||
cmt: true
|
||||
MM_TEST_SERVER_URL: ${{ matrix.server.url }}
|
||||
DESKTOP_VERSION: ${{ inputs.DESKTOP_VERSION }}
|
||||
MM_SERVER_VERSION: ${{ matrix.server.version }}
|
||||
|
||||
# We need to duplicate here in order to set the proper commit status
|
||||
# https://mattermost.atlassian.net/browse/CLD-5815
|
||||
update-failure-final-status:
|
||||
runs-on: ubuntu-22.04
|
||||
if: failure() || cancelled()
|
||||
needs:
|
||||
- calculate-commit-hash
|
||||
- e2e
|
||||
steps:
|
||||
- uses: mattermost/actions/delivery/update-commit-status@746563b58e737a17a8ceb00b84a813b9e6e1b236
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
repository_full_name: mattermost/desktop
|
||||
commit_sha: ${{ needs.calculate-commit-hash.outputs.DESKTOP_SHA }}
|
||||
context: e2e/compatibility-matrix-testing
|
||||
description: "Compatibility Matrix Testing for ${{ inputs.DESKTOP_VERSION }} version"
|
||||
status: failure
|
||||
|
||||
# https://mattermost.atlassian.net/browse/CLD-5815
|
||||
update-success-final-status:
|
||||
runs-on: ubuntu-22.04
|
||||
if: success()
|
||||
needs:
|
||||
- calculate-commit-hash
|
||||
- e2e
|
||||
steps:
|
||||
- uses: mattermost/actions/delivery/update-commit-status@746563b58e737a17a8ceb00b84a813b9e6e1b236
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
repository_full_name: mattermost/desktop
|
||||
commit_sha: ${{ needs.calculate-commit-hash.outputs.DESKTOP_SHA }}
|
||||
context: e2e/compatibility-matrix-testing
|
||||
description: "Compatibility Matrix Testing for ${{ inputs.DESKTOP_VERSION }} version"
|
||||
status: success
|
209
.github/workflows/e2e-functional-template.yml
vendored
209
.github/workflows/e2e-functional-template.yml
vendored
|
@ -1,209 +0,0 @@
|
|||
name: E2E Functional Tests Template
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
MM_TEST_SERVER_URL:
|
||||
description: "The test server URL"
|
||||
required: false
|
||||
type: string
|
||||
MM_TEST_USER_NAME:
|
||||
description: "The admin username of the test instance"
|
||||
required: false
|
||||
type: string
|
||||
MM_TEST_PASSWORD:
|
||||
description: "The admin password of the test instance"
|
||||
required: false
|
||||
type: string
|
||||
DESKTOP_VERSION:
|
||||
description: "The desktop version to test"
|
||||
required: false
|
||||
default: ${{ github.ref }}
|
||||
type: string
|
||||
runs-on:
|
||||
type: string
|
||||
description: "The E2E tests underlying OS"
|
||||
required: true
|
||||
default: "ubuntu-22.04"
|
||||
nightly:
|
||||
type: boolean
|
||||
description: "True if this is nigtly build"
|
||||
required: false
|
||||
default: false
|
||||
cmt:
|
||||
type: boolean
|
||||
description: "True if this is Compatibility Matrix Testing"
|
||||
required: false
|
||||
default: false
|
||||
MM_SERVER_VERSION:
|
||||
type: string
|
||||
required: false
|
||||
default: "9.9.1"
|
||||
outputs:
|
||||
COMMENT_BODY:
|
||||
description: "The output to comment"
|
||||
value: ${{ jobs.e2e.outputs.COMMENT_BODY }}
|
||||
|
||||
env:
|
||||
AWS_S3_BUCKET: "mattermost-cypress-report"
|
||||
BRANCH: ${{ github.head_ref || github.ref_name }}
|
||||
BUILD_TAG: ${{ github.event.pull_request.head.sha || github.sha }}
|
||||
JIRA_PROJECT_KEY: "MM"
|
||||
MM_TEST_SERVER_URL: ${{ inputs.MM_TEST_SERVER_URL || secrets.MM_DESKTOP_E2E_SERVER_URL }}
|
||||
MM_TEST_USER_NAME: ${{ inputs.MM_TEST_USER_NAME || secrets.MM_DESKTOP_E2E_USER_NAME }}
|
||||
MM_TEST_PASSWORD: ${{ inputs.MM_TEST_PASSWORD || secrets.MM_DESKTOP_E2E_USER_CREDENTIALS }}
|
||||
PULL_REQUEST: "https://github.com/mattermost/desktop/pull/${{ github.event.number }}"
|
||||
ZEPHYR_ENVIRONMENT_NAME: "Desktop app"
|
||||
ZEPHYR_FOLDER_ID: "12413253"
|
||||
TEST_CYCLE_LINK_PREFIX: ${{ secrets.MM_DESKTOP_E2E_TEST_CYCLE_LINK_PREFIX }}
|
||||
AWS_ACCESS_KEY_ID: ${{ secrets.MM_DESKTOP_E2E_AWS_ACCESS_KEY_ID }}
|
||||
AWS_SECRET_ACCESS_KEY: ${{ secrets.MM_DESKTOP_E2E_AWS_SECRET_ACCESS_KEY }}
|
||||
AWS_REGION: "us-east-1"
|
||||
WEBHOOK_URL: ${{ secrets.MM_DESKTOP_E2E_WEBHOOK_URL }}
|
||||
ZEPHYR_API_KEY: ${{ secrets.MM_DESKTOP_E2E_ZEPHYR_API_KEY }}
|
||||
REPORT_LINK: "none"
|
||||
|
||||
jobs:
|
||||
e2e:
|
||||
runs-on: ${{ inputs.runs-on }}
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
outputs:
|
||||
COMMENT_BODY: ${{ steps.analyze-flaky-tests.outputs.COMMENT_BODY }}
|
||||
steps:
|
||||
- name: e2e/set-required-variables
|
||||
id: variables
|
||||
run: |
|
||||
RUNNER_OS=$(echo "${{ runner.os }}" | tr '[:upper:]' '[:lower:]')
|
||||
|
||||
if [ "${{ github.event_name }}" == "pull_request" ]; then
|
||||
echo "BUILD_SUFFIX=desktop-pr-${RUNNER_OS}" >> $GITHUB_OUTPUT
|
||||
echo "TYPE=PR" >> $GITHUB_ENV
|
||||
|
||||
elif [ "${{ github.event_name }}" == "workflow_dispatch" && "${{ inputs.cmt }}" ]; then
|
||||
echo "BUILD_SUFFIX=desktop-release-${RUNNER_OS}" >> $GITHUB_OUTPUT
|
||||
echo "TYPE=CMT" >> $GITHUB_ENV
|
||||
echo "ZEPHYR_ENABLE=true" >> $GITHUB_ENV
|
||||
echo "ZEPHYR_FOLDER_LINUX_REPORT=12358649" >> $GITHUB_ENV
|
||||
echo "ZEPHYR_FOLDER_MACOS_REPORT=12358650" >> $GITHUB_ENV
|
||||
echo "ZEPHYR_FOLDER_WIN_REPORT=12358651" >> $GITHUB_ENV
|
||||
|
||||
elif [ "${{ github.event_name }}" == "workflow_dispatch" ] && ! ${{ inputs.nightly }}; then
|
||||
echo "BUILD_SUFFIX=desktop-manual-trigger-${RUNNER_OS}" >> $GITHUB_OUTPUT
|
||||
echo "TYPE=MANUAL" >> $GITHUB_ENV
|
||||
|
||||
elif [ "${{ github.event_name }}" == "push" ] && [ "${{ github.ref }}" == "refs/heads/master" ]; then
|
||||
echo "BUILD_SUFFIX=desktop-master-push-${RUNNER_OS}" >> $GITHUB_OUTPUT
|
||||
echo "TYPE=MASTER" >> $GITHUB_ENV
|
||||
echo "ZEPHYR_ENABLE=true" >> $GITHUB_ENV
|
||||
|
||||
elif ${{ inputs.nightly }}; then
|
||||
echo "BUILD_SUFFIX=desktop-nightly-${RUNNER_OS}" >> $GITHUB_OUTPUT
|
||||
echo "TYPE=NIGHTLY" >> $GITHUB_ENV
|
||||
echo "ZEPHYR_ENABLE=true" >> $GITHUB_ENV
|
||||
echo "ZEPHYR_FOLDER_LINUX_REPORT=12363689" >> $GITHUB_ENV
|
||||
echo "ZEPHYR_FOLDER_MACOS_REPORT=12363687" >> $GITHUB_ENV
|
||||
echo "ZEPHYR_FOLDER_WIN_REPORT=12363690" >> $GITHUB_ENV
|
||||
fi
|
||||
|
||||
- name: e2e/set-build-id
|
||||
run: echo "BUILD_ID=${{ github.run_id }}-${{ steps.variables.outputs.BUILD_SUFFIX }}" >> $GITHUB_ENV
|
||||
|
||||
- name: e2e/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ inputs.DESKTOP_VERSION }}
|
||||
|
||||
- name: e2e/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
|
||||
- name: e2e/cache-node-modules
|
||||
id: cache-node-modules
|
||||
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
|
||||
with:
|
||||
path: |
|
||||
node_modules
|
||||
C:\Users\runneradmin\.electron-gyp
|
||||
key: ${{ runner.os }}-build-node-modules-${{ hashFiles('./package-lock.json') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-build-node-modules
|
||||
${{ runner.os }}-build-
|
||||
${{ runner.os }}-
|
||||
|
||||
- name: e2e/setup-python
|
||||
uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # v5.0.0
|
||||
with:
|
||||
python-version: "3.10"
|
||||
|
||||
## Linux Depdendencies
|
||||
- name: e2e/install-dependencies-linux
|
||||
if: runner.os == 'Linux'
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 0
|
||||
run: |
|
||||
wget -qO - https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_22.04/Release.key | sudo apt-key add -
|
||||
wget -qO /usr/local/bin/yq https://github.com/mikefarah/yq/releases/download/v4.20.1/yq_linux_amd64 && chmod a+x /usr/local/bin/yq
|
||||
sudo apt-get update || true && sudo apt-get install -y ca-certificates libxtst-dev libpng++-dev gcc-aarch64-linux-gnu g++-aarch64-linux-gnu jq icnsutils graphicsmagick tzdata xsel
|
||||
npm ci
|
||||
cd e2e
|
||||
npm ci
|
||||
npx electron-rebuild --platform=linux -f -t prod,optional,dev -w robotjs --module-dir ../
|
||||
|
||||
- name: e2e/install-dependencies-macos
|
||||
if: runner.os == 'macOS'
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
jq '.mac.target=["zip"]' electron-builder.json | jq '.mac.gatekeeperAssess=false' > /tmp/electron-builder.json && cp /tmp/electron-builder.json .
|
||||
npm ci
|
||||
cd e2e
|
||||
npm ci
|
||||
npx electron-rebuild --platform=darwin -f -t prod,optional,dev -w robotjs --module-dir ../
|
||||
|
||||
## Windows Dependencies
|
||||
- name: e2e/install-dependencies-windows
|
||||
if: steps.cache-node-modules.outputs.cache-hit != 'true' && runner.os == 'Windows'
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
choco install yq --version 4.15.1 -y
|
||||
npm i -g node-gyp
|
||||
node-gyp install
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers"
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers" --arch arm64
|
||||
npm ci --openssl_fips=''
|
||||
cd e2e
|
||||
npm ci
|
||||
npx electron-rebuild --platform=win32 -f -t prod,optional,dev -w robotjs --module-dir ../
|
||||
|
||||
- name: e2e/run-playright-tests-${{ runner.os }}
|
||||
run: |
|
||||
if [ ${{ runner.os }} == 'Linux' ]; then
|
||||
export DISPLAY=:99
|
||||
Xvfb $DISPLAY -screen 0 1280x960x24 > /dev/null 2>&1 &
|
||||
fi
|
||||
npm run build-test
|
||||
cd e2e
|
||||
npm run run:e2e || true # making job pass even if the tests fail due to flakyness
|
||||
npm run send-report
|
||||
env:
|
||||
SERVER_VERSION: ${{ inputs.MM_SERVER_VERSION}}
|
||||
DESKTOP_VERSION: ${{ inputs.DESKTOP_VERSION }}
|
||||
|
||||
- name: e2e/analyze-flaky-tests
|
||||
id: analyze-flaky-tests
|
||||
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
|
||||
with:
|
||||
script: |
|
||||
process.chdir('./e2e');
|
||||
const { analyzeFlakyTests } = require('./utils/analyze-flaky-test.js');
|
||||
const { commentBody, newFailedTests } = analyzeFlakyTests();
|
||||
core.setOutput('COMMENT_BODY', commentBody);
|
||||
if (newFailedTests.length > 0) {
|
||||
core.setFailed('E2E tests failed.');
|
||||
}
|
129
.github/workflows/e2e-functional.yml
vendored
129
.github/workflows/e2e-functional.yml
vendored
|
@ -1,129 +0,0 @@
|
|||
name: Electron Playwright Tests
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
pull_request:
|
||||
types:
|
||||
- labeled
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
version_name:
|
||||
type: string
|
||||
description: "Desktop Version name eg: 5.6"
|
||||
required: true
|
||||
job_name:
|
||||
type: choice
|
||||
description: "Job name"
|
||||
required: true
|
||||
default: "All"
|
||||
options:
|
||||
- "e2e-linux"
|
||||
- "e2e-macos"
|
||||
- "e2e-windows"
|
||||
- "All"
|
||||
|
||||
jobs:
|
||||
e2e-linux:
|
||||
if: ${{
|
||||
(
|
||||
(inputs.job_name == 'e2e-linux' || inputs.job_name == 'All')
|
||||
&&
|
||||
github.event_name == 'workflow_dispatch'
|
||||
) ||
|
||||
(
|
||||
github.event_name == 'push'
|
||||
) ||
|
||||
(
|
||||
github.event_name == 'pull_request' &&
|
||||
github.event.pull_request.labels &&
|
||||
contains(github.event.pull_request.labels.*.name, 'Run Desktop E2E Tests')
|
||||
)
|
||||
}}
|
||||
uses: ./.github/workflows/e2e-functional-template.yml
|
||||
secrets: inherit
|
||||
with:
|
||||
runs-on: ubuntu-22.04
|
||||
DESKTOP_VERSION: ${{ inputs.version_name || github.head_ref || github.ref }}
|
||||
|
||||
e2e-macos:
|
||||
if: ${{
|
||||
(
|
||||
(inputs.job_name == 'e2e-macos' || inputs.job_name == 'All')
|
||||
&&
|
||||
github.event_name == 'workflow_dispatch'
|
||||
) ||
|
||||
(
|
||||
github.event_name == 'push'
|
||||
) ||
|
||||
(
|
||||
github.event_name == 'pull_request' &&
|
||||
github.event.pull_request.labels &&
|
||||
contains(github.event.pull_request.labels.*.name, 'Run Desktop E2E Tests')
|
||||
)
|
||||
}}
|
||||
uses: ./.github/workflows/e2e-functional-template.yml
|
||||
secrets: inherit
|
||||
with:
|
||||
runs-on: macos-13
|
||||
DESKTOP_VERSION: ${{ inputs.version_name || github.head_ref || github.ref }}
|
||||
|
||||
e2e-windows:
|
||||
if: ${{
|
||||
(
|
||||
(inputs.job_name == 'e2e-windows' || inputs.job_name == 'All')
|
||||
&&
|
||||
github.event_name == 'workflow_dispatch'
|
||||
) ||
|
||||
(
|
||||
github.event_name == 'push'
|
||||
) ||
|
||||
(
|
||||
github.event_name == 'pull_request' &&
|
||||
github.event.pull_request.labels &&
|
||||
contains(github.event.pull_request.labels.*.name, 'Run Desktop E2E Tests')
|
||||
)
|
||||
}}
|
||||
uses: ./.github/workflows/e2e-functional-template.yml
|
||||
secrets: inherit
|
||||
with:
|
||||
runs-on: windows-2022
|
||||
DESKTOP_VERSION: ${{ inputs.version_name || github.head_ref || github.ref }}
|
||||
|
||||
e2e-remove-label:
|
||||
if: ${{ always() && contains(github.event.pull_request.labels.*.name, 'Run Desktop E2E Tests') }}
|
||||
needs: [e2e-linux, e2e-macos, e2e-windows]
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- name: e2e/unify-comments-in-single-comment
|
||||
run: |
|
||||
echo "PR_COMMENT<<EOF" >> "${GITHUB_ENV}"
|
||||
echo "Here are the test results below:" >> "${GITHUB_ENV}"
|
||||
echo "${{ needs.e2e-linux.outputs.COMMENT_BODY }}" >> "${GITHUB_ENV}"
|
||||
echo "${{ needs.e2e-macos.outputs.COMMENT_BODY }}" >> "${GITHUB_ENV}"
|
||||
echo "${{ needs.e2e-windows.outputs.COMMENT_BODY }}" >> "${GITHUB_ENV}"
|
||||
echo "EOF" >> "${GITHUB_ENV}"
|
||||
|
||||
- name: e2e/send-comment-results-in-pr
|
||||
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
|
||||
with:
|
||||
script: |
|
||||
github.rest.issues.createComment({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
body: process.env.PR_COMMENT,
|
||||
});
|
||||
|
||||
- name: e2e/remove-label-from-pr
|
||||
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
|
||||
continue-on-error: true # Label might have been removed manually
|
||||
with:
|
||||
script: |
|
||||
github.rest.issues.removeLabel({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
name: 'Run Desktop E2E Tests',
|
||||
});
|
96
.github/workflows/e2e-performance.yml
vendored
96
.github/workflows/e2e-performance.yml
vendored
|
@ -1,96 +0,0 @@
|
|||
name: E2E Performance Tests (Desktop)
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches: [master]
|
||||
types:
|
||||
- labeled
|
||||
|
||||
env:
|
||||
RESULTS_PATH: e2e/performance/perf-test-report.json
|
||||
|
||||
jobs:
|
||||
build:
|
||||
if: ${{ github.event.label.name == 'Run E2E Performance Tests' }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest]
|
||||
node-version: [16]
|
||||
steps:
|
||||
- name: Add start comment
|
||||
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
|
||||
with:
|
||||
script: |
|
||||
github.rest.issues.createComment({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
body: `E2E Performance Tests started 🏎️`,
|
||||
});
|
||||
|
||||
- name: Set env variable for timestamp
|
||||
run: echo "NOW=$(date +'%Y-%m-%dT%H:%M:%S')" >> $GITHUB_ENV
|
||||
|
||||
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
|
||||
- name: Use Node.js ${{ matrix.node-version }}
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version: ${{ matrix.node-version }}
|
||||
cache: "npm"
|
||||
|
||||
- name: Install packages
|
||||
run: sudo apt-get install libxtst-dev libpng++-dev
|
||||
|
||||
- name: Install dependencies 👨🏻💻
|
||||
run: npm ci
|
||||
|
||||
- name: E2E Performance Tests for Electron 🧪
|
||||
run: ELECTRON_DISABLE_SANDBOX=1 xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" -- cd e2e && npm run test:performance
|
||||
|
||||
- name: Upload artifact to Github
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: perf-test-report.json
|
||||
path: ${{ env.RESULTS_PATH }}
|
||||
if-no-files-found: error
|
||||
retention-days: 14
|
||||
|
||||
- name: Configure AWS credentials
|
||||
uses: aws-actions/configure-aws-credentials@v1
|
||||
with:
|
||||
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_PERFORMANCE_TESTS_PUT_BUCKET }}
|
||||
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_PERFORMANCE_TESTS_PUT_BUCKET }}
|
||||
aws-region: ${{ secrets.AWS_REGION_PERFORMANCE_TESTS_PUT_BUCKET }}
|
||||
mask-aws-account-id: true
|
||||
|
||||
- name: Upload report to S3
|
||||
run: aws s3 cp ${{ env.RESULTS_PATH }} s3://${{ secrets.AWS_BUCKET_PERFORMANCE_TESTS }}/${{ github.head_ref }}-${{ github.sha }}-${{ env.NOW }}.json
|
||||
|
||||
- name: Add results in PR comment
|
||||
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
|
||||
with:
|
||||
script: |
|
||||
const fs = require('fs');
|
||||
const {generateCommentBodyPerformanceTest} = require('./e2e/utils/pr-e2e-durations-report.js');
|
||||
const fileContents = fs.readFileSync('${{ env.RESULTS_PATH }}');
|
||||
github.rest.issues.createComment({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
body: generateCommentBodyPerformanceTest(fileContents),
|
||||
});
|
||||
|
||||
- name: Remove "Run E2E Performance Tests" label
|
||||
if: always()
|
||||
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
|
||||
continue-on-error: true # Label might have been removed manually
|
||||
with:
|
||||
script: |
|
||||
github.rest.issues.removeLabel({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
name: 'Run E2E Performance Tests',
|
||||
});
|
60
.github/workflows/nightly-builds.yaml
vendored
60
.github/workflows/nightly-builds.yaml
vendored
|
@ -1,60 +0,0 @@
|
|||
name: nightly-builds
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: 0 4 * * 0-5
|
||||
|
||||
jobs:
|
||||
tag-nightly-build:
|
||||
runs-on: ubuntu-22.04
|
||||
outputs:
|
||||
tag: ${{ steps.tag-creation.outputs.tag }}
|
||||
steps:
|
||||
- name: nightly/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
- name: nightly/patch-version
|
||||
uses: ./.github/actions/patch-nightly-version
|
||||
- name: nightly/create-nightly-build-tag
|
||||
id: tag-creation
|
||||
run: |
|
||||
git config --global user.email "nightly-build@mattermost.com"
|
||||
git config --global user.name "Nightly Build"
|
||||
git checkout -b "$(jq -r .version package.json)"
|
||||
git add package.json
|
||||
git commit -m "Nightly build $(jq -r .version package.json)"
|
||||
git tag "$(jq -r .version package.json)" -m "Nightly build $(jq -r .version package.json)"
|
||||
git push --tags --force
|
||||
echo "tag=$(jq -r .version package.json)" >> $GITHUB_OUTPUT
|
||||
|
||||
nightly-main:
|
||||
needs:
|
||||
- tag-nightly-build
|
||||
uses: ./.github/workflows/nightly-main.yml
|
||||
secrets: inherit
|
||||
with:
|
||||
tag: ${{ needs.tag-nightly-build.outputs.tag }}
|
||||
|
||||
nightly-rainforest:
|
||||
needs:
|
||||
- tag-nightly-build
|
||||
uses: ./.github/workflows/nightly-rainforest.yml
|
||||
secrets: inherit
|
||||
with:
|
||||
tag: ${{ needs.tag-nightly-build.outputs.tag }}
|
||||
|
||||
nightly-e2e:
|
||||
needs:
|
||||
- tag-nightly-build
|
||||
strategy:
|
||||
matrix:
|
||||
runs-on:
|
||||
- macos-13
|
||||
- ubuntu-22.04
|
||||
- windows-2022
|
||||
uses: ./.github/workflows/e2e-functional-template.yml
|
||||
secrets: inherit
|
||||
with:
|
||||
runs-on: ${{ matrix.runs-on }}
|
||||
nightly: true
|
||||
DESKTOP_VERSION: ${{ needs.tag-nightly-build.outputs.tag }}
|
251
.github/workflows/nightly-main.yml
vendored
251
.github/workflows/nightly-main.yml
vendored
|
@ -1,251 +0,0 @@
|
|||
name: nightly-main
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
tag:
|
||||
description: "Reference tag of the nightly build"
|
||||
required: true
|
||||
type: string
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
tag:
|
||||
description: "Reference tag of the nightly build"
|
||||
required: true
|
||||
type: string
|
||||
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
|
||||
env:
|
||||
TERM: xterm
|
||||
MM_WIN_INSTALLERS: 1
|
||||
REFERENCE: ${{ inputs.tag }}
|
||||
|
||||
jobs:
|
||||
build-linux:
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- name: ci/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ env.REFERENCE }}
|
||||
- name: ci/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: ci/install-dependencies
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
wget -qO - https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_22.04/Release.key | sudo apt-key add -
|
||||
wget -qO /usr/local/bin/yq https://github.com/mikefarah/yq/releases/download/v4.20.1/yq_linux_amd64 && chmod a+x /usr/local/bin/yq
|
||||
sudo apt-get update || true && sudo apt-get install -y ca-certificates libxtst-dev libpng++-dev gcc-aarch64-linux-gnu g++-aarch64-linux-gnu jq icnsutils graphicsmagick tzdata
|
||||
npm ci
|
||||
- name: ci/build
|
||||
run: |
|
||||
mkdir -p ./build/linux
|
||||
npm run package:linux
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/linux
|
||||
- name: ci/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-nightly-main-${{ runner.os }}
|
||||
path: ./build
|
||||
compression-level: 0
|
||||
retention-days: 5 ## No need to keep them since they are uploaded on S3
|
||||
|
||||
build-msi-installer:
|
||||
runs-on: windows-2022
|
||||
steps:
|
||||
- name: nightly/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ env.REFERENCE }}
|
||||
- name: nightly/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: nightly/install-deps
|
||||
shell: powershell
|
||||
run: |
|
||||
choco install yq --version 4.15.1 -y
|
||||
npm i -g node-gyp
|
||||
node-gyp install
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers"
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers" --arch arm64
|
||||
npm ci --openssl_fips=''
|
||||
- name: nightly/test
|
||||
uses: ./.github/actions/test
|
||||
- name: nightly/build
|
||||
shell: powershell
|
||||
env:
|
||||
MM_WIN_INSTALLERS: 1
|
||||
PFX_KEY: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_PFX_KEY }}
|
||||
CSC_KEY_PASSWORD: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_CSC_KEY_PASSWORD }}
|
||||
PFX: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_PFX }}
|
||||
CSC_LINK: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_CSC_LINK }}
|
||||
run: npm run package:windows-installers
|
||||
- name: nightly/package
|
||||
run: |
|
||||
mkdir -p ./build/win-release
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/win-release
|
||||
- name: nightly/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-nightly-main-${{ runner.os }}
|
||||
path: ./build
|
||||
compression-level: 0
|
||||
retention-days: 5 ## No need to keep them since they are uploaded on S3
|
||||
|
||||
mac-app-store-preflight:
|
||||
runs-on: macos-12
|
||||
env:
|
||||
MAS_PROFILE: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_MAS_PROFILE }}
|
||||
MACOS_API_KEY_ID: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_MACOS_API_KEY_ID }}
|
||||
MACOS_API_KEY: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_MACOS_API_KEY }}
|
||||
MACOS_API_ISSUER_ID: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_MACOS_API_ISSUER_ID }}
|
||||
CSC_FOR_PULL_REQUEST: true
|
||||
CSC_KEY_PASSWORD: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_CSC_KEY_PASSWORD}}
|
||||
CSC_LINK: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_CSC_LINK }}
|
||||
steps:
|
||||
- name: nightly/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ env.REFERENCE }}
|
||||
- name: nightly/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: nightly/install-dependencies
|
||||
run: |
|
||||
brew install yq
|
||||
npm ci
|
||||
- name: nightly/copy-provisioning-profile
|
||||
run: echo $MAS_PROFILE | base64 -D > ./mas.provisionprofile
|
||||
- name: nightly/patch-version-number-for-MAS
|
||||
run: ./scripts/patch_mas_version.sh
|
||||
- name: nightly/test
|
||||
uses: ./.github/actions/test
|
||||
- name: nightly/package
|
||||
run: npm run package:mas
|
||||
- name: nightly/publish
|
||||
run: fastlane publish_test path:"$(find . -name \*.pkg -print -quit)"
|
||||
|
||||
build-mac-installer:
|
||||
runs-on: macos-12
|
||||
needs:
|
||||
- mac-app-store-preflight
|
||||
steps:
|
||||
- name: nightly/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ env.REFERENCE }}
|
||||
- name: nightly/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: nightly/install-dependencies
|
||||
run: |
|
||||
brew install yq rename
|
||||
npm ci
|
||||
- name: nightly/test
|
||||
uses: ./.github/actions/test
|
||||
- name: nightly/build
|
||||
env:
|
||||
APPLE_ID: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_APPLE_ID }}
|
||||
APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_APPLE_ID_PASS }}
|
||||
CSC_FOR_PULL_REQUEST: true
|
||||
CSC_KEY_PASSWORD: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_CSC_KEY_PASSWORD }}
|
||||
CSC_LINK: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_CSC_LINK }}
|
||||
MAC_PROFILE: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_DMG_PROFILE }}
|
||||
run: |
|
||||
echo $MAC_PROFILE | base64 -D > ./mac.provisionprofile
|
||||
mkdir -p ./build/macos-release
|
||||
npm run package:mac-with-universal
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/macos-release
|
||||
- name: nightly/rename-arm64-to-m1
|
||||
run: rename 's/arm64/m1/' ./build/macos-release/$(jq -r .version package.json)/*
|
||||
- name: nightly/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-nightly-main-${{ runner.os }}
|
||||
path: ./build
|
||||
compression-level: 0
|
||||
retention-days: 5 ## No need to keep them since they are uploaded on S3
|
||||
|
||||
upload-to-s3:
|
||||
runs-on: ubuntu-22.04
|
||||
outputs:
|
||||
links: ${{ steps.generate-linklist.outputs.linklist }}
|
||||
needs:
|
||||
- build-mac-installer
|
||||
- build-msi-installer
|
||||
- build-linux
|
||||
steps:
|
||||
- name: nightly/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ env.REFERENCE }}
|
||||
- name: nightly/setup-aws-credentials
|
||||
uses: aws-actions/configure-aws-credentials@67fbcbb121271f7775d2e7715933280b06314838 # v1.7.0
|
||||
with:
|
||||
aws-region: us-east-1
|
||||
aws-access-key-id: ${{ secrets.MM_DESKTOP_RELEASE_AWS_ACCESS_KEY_ID }}
|
||||
aws-secret-access-key: ${{ secrets.MM_DESKTOP_RELEASE_AWS_SECRET_ACCESS_KEY }}
|
||||
- name: nightly/download-builds
|
||||
uses: actions/download-artifact@c850b930e6ba138125429b7e5c93fc707a7f8427 # v4.1.4
|
||||
with:
|
||||
path: build
|
||||
pattern: build-nightly-main-*
|
||||
merge-multiple: true
|
||||
- name: nightly/setup-files-for-aws
|
||||
run: |
|
||||
mkdir -p ./aws-s3-dist
|
||||
cp -r --backup=numbered ./build/{macos-release,win-release,linux}/* ./aws-s3-dist
|
||||
- name: nightly/upload-to-s3
|
||||
run: aws s3 cp ./aws-s3-dist/ s3://releases.mattermost.com/desktop/ --acl public-read --cache-control "no-cache" --recursive
|
||||
- name: nightly/generate-linklist
|
||||
id: generate-linklist
|
||||
run: |
|
||||
mkdir -p ./links
|
||||
echo "### Nightly builds:" > ./links/linklist.txt
|
||||
echo "Links for $(date +"%b-%d-%Y")" >> ./links/linklist.txt
|
||||
echo "##### :tux: Linux" >> ./links/linklist.txt
|
||||
for i in `ls ./build/linux/$(jq -r .version package.json)/` ; do echo "- [$i](https://s3.amazonaws.com/releases.mattermost.com/desktop/$(jq -r .version package.json)/$i)" ; done >> ./links/linklist.txt
|
||||
echo "##### :apple_logo: macOS" >> ./links/linklist.txt
|
||||
for i in `ls ./build/macos-release/$(jq -r .version package.json)/` ; do echo "- [$i](https://s3.amazonaws.com/releases.mattermost.com/desktop/$(jq -r .version package.json)/$i)" ; done >> ./links/linklist.txt
|
||||
echo "##### :windows: Windows" >> ./links/linklist.txt
|
||||
for i in `ls ./build/win-release/$(jq -r .version package.json)/` ; do echo "- [$i](https://s3.amazonaws.com/releases.mattermost.com/desktop/$(jq -r .version package.json)/$i)" ; done >> ./links/linklist.txt
|
||||
cat ./links/linklist.txt
|
||||
LINKLIST=$(<./links/linklist.txt)
|
||||
## https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#multiline-strings
|
||||
echo 'linklist<<EOF' >> $GITHUB_OUTPUT
|
||||
echo "$LINKLIST" >> $GITHUB_OUTPUT
|
||||
echo 'EOF' >> $GITHUB_OUTPUT
|
||||
|
||||
share-links-to-channel:
|
||||
runs-on: ubuntu-22.04
|
||||
needs:
|
||||
- upload-to-s3
|
||||
steps:
|
||||
- name: nightly/share-links-to-channel
|
||||
run: |
|
||||
jq --null-input \
|
||||
--arg icon_url "https://upload.wikimedia.org/wikipedia/commons/1/17/Luna_symbol.png" \
|
||||
--arg username "NightBuilder" \
|
||||
--arg text "${{ needs.upload-to-s3.outputs.links }}" \
|
||||
'{"username":$username,"icon_url": $icon_url, "text": $text }' > /tmp/webhook-data.json
|
||||
curl -i -X POST -H "Content-Type: application/json" -d @/tmp/webhook-data.json ${{ secrets.MM_DESKTOP_NIGHTLY_WEBHOOK_URL }}
|
149
.github/workflows/nightly-rainforest.yml
vendored
149
.github/workflows/nightly-rainforest.yml
vendored
|
@ -1,149 +0,0 @@
|
|||
name: nightly-rainforest
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
tag:
|
||||
description: "Reference tag of the nightly build"
|
||||
required: true
|
||||
type: string
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
tag:
|
||||
description: "Reference tag of the nightly build"
|
||||
required: true
|
||||
type: string
|
||||
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
|
||||
env:
|
||||
TERM: xterm
|
||||
MM_DESKTOP_BUILD_DISABLEGPU: true
|
||||
MM_DESKTOP_BUILD_SKIPONBOARDINGSCREENS: true
|
||||
MM_WIN_INSTALLERS: 1
|
||||
REFERENCE: ${{ inputs.tag }}
|
||||
|
||||
jobs:
|
||||
build-msi-installer:
|
||||
runs-on: windows-2022
|
||||
steps:
|
||||
- name: nightly/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ env.REFERENCE }}
|
||||
- name: nightly/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: nightly/install-deps
|
||||
shell: powershell
|
||||
run: |
|
||||
choco install yq --version 4.15.1 -y
|
||||
npm i -g node-gyp
|
||||
node-gyp install
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers"
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers" --arch arm64
|
||||
npm ci --openssl_fips=''
|
||||
- name: nightly/test
|
||||
uses: ./.github/actions/test
|
||||
- name: nightly/build
|
||||
shell: powershell
|
||||
env:
|
||||
MM_WIN_INSTALLERS: 1
|
||||
PFX_KEY: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_PFX_KEY }}
|
||||
CSC_KEY_PASSWORD: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_CSC_KEY_PASSWORD }}
|
||||
PFX: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_PFX }}
|
||||
CSC_LINK: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_CSC_LINK }}
|
||||
run: npm run package:windows-installers
|
||||
- name: nightly/package
|
||||
run: |
|
||||
mkdir -p ./build/win
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/win
|
||||
- name: nightly/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-rainforest-${{ runner.os }}
|
||||
path: ./build
|
||||
compression-level: 0
|
||||
retention-days: 5 ## No need to keep them since they are uploaded on S3
|
||||
|
||||
build-mac-installer:
|
||||
runs-on: macos-12
|
||||
steps:
|
||||
- name: nightly/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ env.REFERENCE }}
|
||||
- name: nightly/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: nightly/install-dependencies
|
||||
run: |
|
||||
brew install yq rename
|
||||
npm ci
|
||||
- name: nightly/test
|
||||
uses: ./.github/actions/test
|
||||
- name: nightly/build
|
||||
env:
|
||||
APPLE_ID: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_APPLE_ID }}
|
||||
APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_APPLE_ID_PASS }}
|
||||
CSC_FOR_PULL_REQUEST: true
|
||||
CSC_KEY_PASSWORD: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_CSC_KEY_PASSWORD }}
|
||||
CSC_LINK: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_CSC_LINK }}
|
||||
MAC_PROFILE: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_DMG_PROFILE }}
|
||||
run: |
|
||||
echo $MAC_PROFILE | base64 -D > ./mac.provisionprofile
|
||||
mkdir -p ./build/macos
|
||||
npm run package:mac-with-universal
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/macos
|
||||
- name: nightly/rename-arm64-to-m1
|
||||
run: rename 's/arm64/m1/' ./build/macos/$(jq -r .version package.json)/*
|
||||
- name: nightly/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-rainforest-${{ runner.os }}
|
||||
path: ./build
|
||||
compression-level: 0
|
||||
retention-days: 5 ## No need to keep them since they are uploaded on S3
|
||||
|
||||
upload-to-s3-daily:
|
||||
runs-on: ubuntu-22.04
|
||||
needs:
|
||||
- build-mac-installer
|
||||
- build-msi-installer
|
||||
steps:
|
||||
- name: nightly/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
ref: ${{ env.REFERENCE }}
|
||||
- name: nightly/setup-aws-credentials
|
||||
uses: aws-actions/configure-aws-credentials@67fbcbb121271f7775d2e7715933280b06314838 # v1.7.0
|
||||
with:
|
||||
aws-region: us-east-1
|
||||
aws-access-key-id: ${{ secrets.MM_DESKTOP_DAILY_AWS_ACCESS_KEY_ID }}
|
||||
aws-secret-access-key: ${{ secrets.MM_DESKTOP_DAILY_AWS_SECRET_ACCESS_KEY }}
|
||||
- name: nightly/download-builds
|
||||
uses: actions/download-artifact@c850b930e6ba138125429b7e5c93fc707a7f8427 # v4.1.4
|
||||
with:
|
||||
path: build
|
||||
pattern: build-rainforest-*
|
||||
merge-multiple: true
|
||||
- name: nightly/install-missing-deps
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install rename jq -y
|
||||
- name: nightly/setup-files-for-aws
|
||||
run: |
|
||||
rename 's/\d+\.\d+\.\d+\-nightly\.\d+\/mattermost(.+)\d+\.\d+\.\d+\-nightly\.\d+/mattermost$1daily-develop/' ./build/macos/$(jq -r .version package.json)/*
|
||||
rename 's/\d+\.\d+\.\d+\-nightly\.\d+\/mattermost(.+)\d+\.\d+\.\d+\-nightly\.\d+/mattermost$1daily-develop/' ./build/win/$(jq -r .version package.json)/*
|
||||
- name: nightly/upload-to-s3
|
||||
run: aws s3 cp ./build/ s3://mattermost-desktop-daily-builds/ --acl public-read --cache-control "no-cache" --recursive
|
49
.github/workflows/release-mas.yaml
vendored
49
.github/workflows/release-mas.yaml
vendored
|
@ -1,49 +0,0 @@
|
|||
name: release-mas
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "v[0-9]+.[0-9]+.[0-9]+-rc.[0-9]+"
|
||||
- "v[0-9]+.[0-9]+.[0-9]+-mas.[0-9]+"
|
||||
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
|
||||
env:
|
||||
TERM: xterm
|
||||
|
||||
jobs:
|
||||
mac-app-store-preflight:
|
||||
runs-on: macos-12
|
||||
env:
|
||||
MAS_PROFILE: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_MAS_PROFILE }}
|
||||
MACOS_API_KEY_ID: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_MACOS_API_KEY_ID }}
|
||||
MACOS_API_KEY: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_MACOS_API_KEY }}
|
||||
MACOS_API_ISSUER_ID: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_MACOS_API_ISSUER_ID }}
|
||||
CSC_FOR_PULL_REQUEST: true
|
||||
CSC_KEY_PASSWORD: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_CSC_KEY_PASSWORD}}
|
||||
CSC_LINK: ${{ secrets.MM_DESKTOP_MAC_APP_STORE_CSC_LINK }}
|
||||
steps:
|
||||
- name: release/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
- name: release/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: release/install-dependencies
|
||||
run: |
|
||||
brew install yq
|
||||
npm ci
|
||||
- name: release/copy-provisioning-profile
|
||||
run: echo $MAS_PROFILE | base64 -D > ./mas.provisionprofile
|
||||
- name: release/patch-version-number-for-MAS
|
||||
run: ./scripts/patch_mas_version.sh
|
||||
- name: release/test
|
||||
uses: ./.github/actions/test
|
||||
- name: release/package
|
||||
run: npm run package:mas
|
||||
- name: release/publish
|
||||
run: fastlane publish_test path:"$(find . -name \*.pkg -print -quit)"
|
248
.github/workflows/release.yaml
vendored
248
.github/workflows/release.yaml
vendored
|
@ -1,248 +0,0 @@
|
|||
name: release
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "v[0-9]+.[0-9]+.[0-9]+"
|
||||
- "v[0-9]+.[0-9]+.[0-9]+-rc.[0-9]+"
|
||||
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
|
||||
env:
|
||||
TERM: xterm
|
||||
MM_WIN_INSTALLERS: 1
|
||||
|
||||
jobs:
|
||||
begin-notification:
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- name: release/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
|
||||
- name: release/fetch-version
|
||||
id: calc
|
||||
run: echo "VERSION=$(jq -r .version package.json)" >> ${GITHUB_OUTPUT}
|
||||
|
||||
- name: release/notify-channel
|
||||
uses: mattermost/action-mattermost-notify@60f5da6e1796b033cf5a038b57031fa011962e27
|
||||
with:
|
||||
MATTERMOST_WEBHOOK_URL: ${{ secrets.MM_DESKTOP_RELEASE_WEBHOOK_URL }}
|
||||
MATTERMOST_USERNAME: MattermostRelease
|
||||
MATTERMOST_ICON_URL: https://mattermost.com/wp-content/uploads/2022/02/icon.png
|
||||
TEXT: |
|
||||
[${{ steps.calc.outputs.VERSION }}] Release process for the desktop app has started, it should take about 30 minutes to complete.
|
||||
|
||||
build-linux:
|
||||
runs-on: ubuntu-22.04
|
||||
needs:
|
||||
- begin-notification
|
||||
steps:
|
||||
- name: release/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
- name: release/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: release/install-dependencies
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
run: |
|
||||
wget -qO - https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_22.04/Release.key | sudo apt-key add -
|
||||
wget -qO /usr/local/bin/yq https://github.com/mikefarah/yq/releases/download/v4.20.1/yq_linux_amd64 && chmod a+x /usr/local/bin/yq
|
||||
sudo apt-get update || true && sudo apt-get install -y ca-certificates libxtst-dev libpng++-dev gcc-aarch64-linux-gnu g++-aarch64-linux-gnu jq icnsutils graphicsmagick tzdata
|
||||
npm ci
|
||||
- name: release/test
|
||||
uses: ./.github/actions/test
|
||||
- name: release/build
|
||||
run: |
|
||||
mkdir -p ./build/linux
|
||||
npm run package:linux
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/linux
|
||||
- name: release/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-${{ runner.os }}
|
||||
path: ./build
|
||||
compression-level: 0
|
||||
retention-days: 14 ## No need to keep CI builds more than 14 days
|
||||
|
||||
build-msi-installer:
|
||||
runs-on: windows-2022
|
||||
needs:
|
||||
- begin-notification
|
||||
steps:
|
||||
- name: release/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
- name: release/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: release/install-deps
|
||||
shell: powershell
|
||||
run: |
|
||||
choco install yq --version 4.15.1 -y
|
||||
npm i -g node-gyp
|
||||
node-gyp install
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers"
|
||||
node-gyp install --devdir="C:\Users\runneradmin\.electron-gyp" --target=$(jq -r .devDependencies.electron package.json) --dist-url="https://electronjs.org/headers" --arch arm64
|
||||
npm ci --openssl_fips=''
|
||||
- name: release/test
|
||||
uses: ./.github/actions/test
|
||||
- name: release/build
|
||||
shell: powershell
|
||||
env:
|
||||
MM_WIN_INSTALLERS: 1
|
||||
PFX_KEY: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_PFX_KEY }}
|
||||
CSC_KEY_PASSWORD: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_CSC_KEY_PASSWORD }}
|
||||
PFX: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_PFX }}
|
||||
CSC_LINK: ${{ secrets.MM_DESKTOP_MSI_INSTALLER_CSC_LINK }}
|
||||
run: |
|
||||
npm run package:windows
|
||||
- name: release/package
|
||||
run: |
|
||||
mkdir -p ./build/win-release
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/win-release
|
||||
- name: release/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-${{ runner.os }}
|
||||
path: ./build
|
||||
compression-level: 0
|
||||
retention-days: 14
|
||||
|
||||
build-mac-installer:
|
||||
runs-on: macos-12
|
||||
needs:
|
||||
- begin-notification
|
||||
steps:
|
||||
- name: release/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
- name: release/setup-node
|
||||
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
|
||||
with:
|
||||
node-version-file: "package.json"
|
||||
cache: "npm"
|
||||
cache-dependency-path: package-lock.json
|
||||
- name: release/create-build-folder
|
||||
run: mkdir -p ./build
|
||||
- name: release/install-dependencies
|
||||
run: |
|
||||
brew install yq rename
|
||||
npm ci
|
||||
- name: release/test
|
||||
uses: ./.github/actions/test
|
||||
- name: release/build
|
||||
env:
|
||||
APPLE_ID: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_APPLE_ID }}
|
||||
APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_APPLE_ID_PASS }}
|
||||
CSC_FOR_PULL_REQUEST: true
|
||||
CSC_KEY_PASSWORD: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_CSC_KEY_PASSWORD }}
|
||||
CSC_LINK: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_CSC_LINK }}
|
||||
MAC_PROFILE: ${{ secrets.MM_DESKTOP_MAC_INSTALLER_DMG_PROFILE }}
|
||||
run: |
|
||||
echo $MAC_PROFILE | base64 -D > ./mac.provisionprofile
|
||||
mkdir -p ./build/macos-release
|
||||
npm run package:mac-with-universal
|
||||
bash -x ./scripts/patch_updater_yml.sh
|
||||
bash -x ./scripts/cp_artifacts.sh release ./build/macos-release
|
||||
- name: release/rename-arm64-to-m1
|
||||
run: rename 's/arm64/m1/' ./build/macos-release/$(jq -r .version package.json)/*
|
||||
- name: release/upload-build
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: build-${{ runner.os }}
|
||||
path: ./build
|
||||
compression-level: 0
|
||||
retention-days: 14
|
||||
|
||||
upload-to-s3:
|
||||
runs-on: ubuntu-22.04
|
||||
needs:
|
||||
- build-mac-installer
|
||||
- build-msi-installer
|
||||
- build-linux
|
||||
steps:
|
||||
- name: release/setup-aws-credentials
|
||||
uses: aws-actions/configure-aws-credentials@67fbcbb121271f7775d2e7715933280b06314838 # v1.7.0
|
||||
with:
|
||||
aws-region: us-east-1
|
||||
aws-access-key-id: ${{ secrets.MM_DESKTOP_RELEASE_AWS_ACCESS_KEY_ID }}
|
||||
aws-secret-access-key: ${{ secrets.MM_DESKTOP_RELEASE_AWS_SECRET_ACCESS_KEY }}
|
||||
|
||||
- name: release/download-builds
|
||||
uses: actions/download-artifact@c850b930e6ba138125429b7e5c93fc707a7f8427 # v4.1.4
|
||||
with:
|
||||
path: build
|
||||
pattern: build-*
|
||||
merge-multiple: true
|
||||
|
||||
- name: release/setup-files-for-aws
|
||||
run: |
|
||||
mkdir -p ./aws-s3-dist
|
||||
cp -r --backup=numbered ./build/{macos-release,win-release,linux}/* ./aws-s3-dist
|
||||
- name: release/upload-to-s3
|
||||
run: aws s3 cp ./aws-s3-dist/ s3://releases.mattermost.com/desktop/ --acl public-read --cache-control "no-cache" --recursive
|
||||
|
||||
github-release:
|
||||
runs-on: ubuntu-22.04
|
||||
needs:
|
||||
- upload-to-s3
|
||||
steps:
|
||||
- name: release/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
|
||||
- name: release/download-builds
|
||||
uses: actions/download-artifact@c850b930e6ba138125429b7e5c93fc707a7f8427 # v4.1.4
|
||||
with:
|
||||
path: build
|
||||
pattern: build-*
|
||||
merge-multiple: true
|
||||
|
||||
- name: release/setup-files-for-github-release
|
||||
run: |
|
||||
mkdir -p ./ghr-dist
|
||||
find ./build/{macos-release,win-release,linux} -type f -exec cp --backup=numbered -t ./ghr-dist {} +
|
||||
|
||||
- name: release/publish-release
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.MATTERMOST_BUILD_GH_TOKEN }}
|
||||
run: |
|
||||
VERSION=$(jq -r .version package.json)
|
||||
./scripts/generate_release_markdown.sh ${VERSION} > release-notes.md
|
||||
RELEASE_TITLE="v${VERSION} ($(date -u "+%Y-%m-%d"))"
|
||||
[[ $VERSION =~ "-rc" ]] && PRERELEASE="--prerelease"
|
||||
gh release create --draft ${PRERELEASE} --verify-tag -F release-notes.md --target "${GITHUB_SHA}" --title "${RELEASE_TITLE}" "${GITHUB_REF_NAME}" ./ghr-dist/*
|
||||
|
||||
end-notification:
|
||||
runs-on: ubuntu-22.04
|
||||
needs:
|
||||
- github-release
|
||||
steps:
|
||||
- name: release/checkout-repo
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: release/fetch-version
|
||||
id: calc
|
||||
run: |
|
||||
echo "BODY<<EOF" >> "${GITHUB_OUTPUT}"
|
||||
bash -x scripts/generate_release_post.sh $(jq -r .version package.json) >> "${GITHUB_OUTPUT}"
|
||||
echo "EOF" >> "${GITHUB_OUTPUT}"
|
||||
|
||||
- name: release/notify-channel
|
||||
uses: mattermost/action-mattermost-notify@60f5da6e1796b033cf5a038b57031fa011962e27
|
||||
with:
|
||||
MATTERMOST_WEBHOOK_URL: ${{ secrets.MM_DESKTOP_RELEASE_WEBHOOK_URL }}
|
||||
MATTERMOST_USERNAME: MattermostRelease
|
||||
MATTERMOST_ICON_URL: https://mattermost.com/wp-content/uploads/2022/02/icon.png
|
||||
TEXT: |
|
||||
${{ steps.calc.outputs.BODY }}
|
47
.github/workflows/scorecards-analysis.yml
vendored
47
.github/workflows/scorecards-analysis.yml
vendored
|
@ -1,47 +0,0 @@
|
|||
name: Scorecards supply-chain security
|
||||
on:
|
||||
# Only the default branch is supported.
|
||||
branch_protection_rule:
|
||||
schedule:
|
||||
- cron: "44 7 * * 5"
|
||||
push:
|
||||
branches: [master]
|
||||
|
||||
# Declare default permissions as read only.
|
||||
permissions: read-all
|
||||
|
||||
jobs:
|
||||
analysis:
|
||||
name: Scorecards analysis
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
# Needed if using Code scanning alerts
|
||||
security-events: write
|
||||
# Needed for GitHub OIDC token if publish_results is true
|
||||
id-token: write
|
||||
steps:
|
||||
- name: "Checkout code"
|
||||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
- name: "Run analysis"
|
||||
uses: ossf/scorecard-action@0864cf19026789058feabb7e87baa5f140aac736 # v2.3.1
|
||||
with:
|
||||
results_file: results.sarif
|
||||
results_format: sarif
|
||||
publish_results: true
|
||||
|
||||
# Upload the results as artifacts (optional).
|
||||
- name: "Upload artifact"
|
||||
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
||||
with:
|
||||
name: SARIF file
|
||||
path: results.sarif
|
||||
retention-days: 5
|
||||
|
||||
# Upload the results to GitHub's code scanning dashboard.
|
||||
- name: "Upload to code-scanning"
|
||||
uses: github/codeql-action/upload-sarif@423a04bb2cb7cd2643007122588f1387778f14d0 # v2.16.5
|
||||
with:
|
||||
sarif_file: results.sarif
|
4
.gitignore
vendored
4
.gitignore
vendored
|
@ -5,6 +5,10 @@ Thumbs.db
|
|||
node_modules/
|
||||
*_bundle.js
|
||||
#release*/
|
||||
release/builder-debug.yml
|
||||
release/builder-effective-config.yaml
|
||||
.gitlab-ci.yml
|
||||
.github/workflows
|
||||
npm-debug.log*
|
||||
|
||||
build/
|
||||
|
|
|
@ -1,8 +0,0 @@
|
|||
---
|
||||
|
||||
include:
|
||||
- project: mattermost/ci/desktop
|
||||
ref: main
|
||||
file: private.yml
|
||||
|
||||
|
|
@ -1,74 +0,0 @@
|
|||
x64:
|
||||
firstOrDefaultFilePatterns:
|
||||
- '!**/node_modules'
|
||||
- '!src/assets{,/**/*}'
|
||||
- '!release{,/**/*}'
|
||||
- '!node_modules/**/*'
|
||||
- node_modules/bindings/**/*
|
||||
- node_modules/file-uri-to-path/**/*
|
||||
- node_modules/macos-notification-state/**/*
|
||||
- node_modules/windows-focus-assist/**/*
|
||||
- '!**/node_modules/macos-notification-state/bin/**/*'
|
||||
- '!**/node_modules/macos-notification-state/build/**/*'
|
||||
- '!**/node_modules/windows-focus-assist/bin/**/*'
|
||||
- '!**/node_modules/windows-focus-assist/build/**/*'
|
||||
- node_modules/macos-notification-state/build/**/*.node
|
||||
- node_modules/windows-focus-assist/build/Release/**/*.node
|
||||
- package.json
|
||||
- '!**/*.{iml,hprof,orig,pyc,pyo,rbc,swp,csproj,sln,suo,xproj,cc,d.ts,mk,a,o,forge-meta,pdb}'
|
||||
- '!**/._*'
|
||||
- '!**/electron-builder.{yaml,yml,json,json5,toml,ts}'
|
||||
- '!**/{.git,.hg,.svn,CVS,RCS,SCCS,__pycache__,.DS_Store,thumbs.db,.gitignore,.gitkeep,.gitattributes,.npmignore,.idea,.vs,.flowconfig,.jshintrc,.eslintrc,.circleci,.yarn-integrity,.yarn-metadata.json,yarn-error.log,yarn.lock,package-lock.json,npm-debug.log,appveyor.yml,.travis.yml,circle.yml,.nyc_output,.husky,.github,electron-builder.env}'
|
||||
- '!.yarn{,/**/*}'
|
||||
- '!.editorconfig'
|
||||
- '!.yarnrc.yml'
|
||||
nodeModuleFilePatterns:
|
||||
- '**/*'
|
||||
- '!node_modules/**/*'
|
||||
- node_modules/bindings/**/*
|
||||
- node_modules/file-uri-to-path/**/*
|
||||
- node_modules/macos-notification-state/**/*
|
||||
- node_modules/windows-focus-assist/**/*
|
||||
- '!**/node_modules/macos-notification-state/bin/**/*'
|
||||
- '!**/node_modules/macos-notification-state/build/**/*'
|
||||
- '!**/node_modules/windows-focus-assist/bin/**/*'
|
||||
- '!**/node_modules/windows-focus-assist/build/**/*'
|
||||
- node_modules/macos-notification-state/build/**/*.node
|
||||
- node_modules/windows-focus-assist/build/Release/**/*.node
|
||||
arm64:
|
||||
firstOrDefaultFilePatterns:
|
||||
- '!**/node_modules'
|
||||
- '!src/assets{,/**/*}'
|
||||
- '!release{,/**/*}'
|
||||
- '!node_modules/**/*'
|
||||
- node_modules/bindings/**/*
|
||||
- node_modules/file-uri-to-path/**/*
|
||||
- node_modules/macos-notification-state/**/*
|
||||
- node_modules/windows-focus-assist/**/*
|
||||
- '!**/node_modules/macos-notification-state/bin/**/*'
|
||||
- '!**/node_modules/macos-notification-state/build/**/*'
|
||||
- '!**/node_modules/windows-focus-assist/bin/**/*'
|
||||
- '!**/node_modules/windows-focus-assist/build/**/*'
|
||||
- node_modules/macos-notification-state/build/**/*.node
|
||||
- node_modules/windows-focus-assist/build/Release/**/*.node
|
||||
- package.json
|
||||
- '!**/*.{iml,hprof,orig,pyc,pyo,rbc,swp,csproj,sln,suo,xproj,cc,d.ts,mk,a,o,forge-meta,pdb}'
|
||||
- '!**/._*'
|
||||
- '!**/electron-builder.{yaml,yml,json,json5,toml,ts}'
|
||||
- '!**/{.git,.hg,.svn,CVS,RCS,SCCS,__pycache__,.DS_Store,thumbs.db,.gitignore,.gitkeep,.gitattributes,.npmignore,.idea,.vs,.flowconfig,.jshintrc,.eslintrc,.circleci,.yarn-integrity,.yarn-metadata.json,yarn-error.log,yarn.lock,package-lock.json,npm-debug.log,appveyor.yml,.travis.yml,circle.yml,.nyc_output,.husky,.github,electron-builder.env}'
|
||||
- '!.yarn{,/**/*}'
|
||||
- '!.editorconfig'
|
||||
- '!.yarnrc.yml'
|
||||
nodeModuleFilePatterns:
|
||||
- '**/*'
|
||||
- '!node_modules/**/*'
|
||||
- node_modules/bindings/**/*
|
||||
- node_modules/file-uri-to-path/**/*
|
||||
- node_modules/macos-notification-state/**/*
|
||||
- node_modules/windows-focus-assist/**/*
|
||||
- '!**/node_modules/macos-notification-state/bin/**/*'
|
||||
- '!**/node_modules/macos-notification-state/build/**/*'
|
||||
- '!**/node_modules/windows-focus-assist/bin/**/*'
|
||||
- '!**/node_modules/windows-focus-assist/build/**/*'
|
||||
- node_modules/macos-notification-state/build/**/*.node
|
||||
- node_modules/windows-focus-assist/build/Release/**/*.node
|
|
@ -1,141 +0,0 @@
|
|||
directories:
|
||||
output: release
|
||||
buildResources: src/assets
|
||||
publish:
|
||||
- provider: generic
|
||||
url: https://gitlab.peanutsmediaserver.com/aaron/mattermost-desktop
|
||||
appId: Mattermost.Desktop
|
||||
artifactName: ${version}/${name}-${version}-${os}-${arch}.${ext}
|
||||
extraMetadata:
|
||||
main: index.js
|
||||
files:
|
||||
- filter:
|
||||
- '!node_modules/**/*'
|
||||
- node_modules/bindings/**/*
|
||||
- node_modules/file-uri-to-path/**/*
|
||||
- node_modules/macos-notification-state/**/*
|
||||
- node_modules/windows-focus-assist/**/*
|
||||
- '!**/node_modules/macos-notification-state/bin/**/*'
|
||||
- '!**/node_modules/macos-notification-state/build/**/*'
|
||||
- '!**/node_modules/windows-focus-assist/bin/**/*'
|
||||
- '!**/node_modules/windows-focus-assist/build/**/*'
|
||||
- node_modules/macos-notification-state/build/**/*.node
|
||||
- node_modules/windows-focus-assist/build/Release/**/*.node
|
||||
- from: dist
|
||||
filter:
|
||||
- '**/*'
|
||||
protocols:
|
||||
- name: Mattermost
|
||||
schemes:
|
||||
- mattermost
|
||||
beforePack: scripts/beforepack.js
|
||||
afterPack: scripts/afterpack.js
|
||||
afterAllArtifactBuild: scripts/afterbuild.js
|
||||
deb:
|
||||
artifactName: ${version}/${name}_${version}-1_${arch}.${ext}
|
||||
synopsis: Mattermost Desktop App
|
||||
depends:
|
||||
- libnotify4
|
||||
- libxtst6
|
||||
- libnss3
|
||||
priority: optional
|
||||
asarUnpack:
|
||||
- ./node_modules/macos-notification-state/build/Release/**/*.node
|
||||
- ./node_modules/windows-focus-assist/build/Release/**/*.node
|
||||
linux:
|
||||
category: Network;InstantMessaging
|
||||
target:
|
||||
- deb
|
||||
- tar.gz
|
||||
- appimage
|
||||
- rpm
|
||||
extraFiles:
|
||||
- filter:
|
||||
- LICENSE.txt
|
||||
- NOTICE.txt
|
||||
- from: src/assets/linux
|
||||
filter:
|
||||
- create_desktop_file.sh
|
||||
- app_icon.png
|
||||
- README.md
|
||||
appImage:
|
||||
executableArgs:
|
||||
- ' '
|
||||
mac:
|
||||
category: public.app-category.productivity
|
||||
target:
|
||||
- zip
|
||||
- dmg
|
||||
darkModeSupport: true
|
||||
extraResources:
|
||||
- filter:
|
||||
- LICENSE.txt
|
||||
- NOTICE.txt
|
||||
hardenedRuntime: true
|
||||
gatekeeperAssess: true
|
||||
entitlements: ./resources/mac/entitlements.mac.plist
|
||||
entitlementsInherit: ./resources/mac/entitlements.mac.inherit.plist
|
||||
extendInfo:
|
||||
NSMicrophoneUsageDescription: Microphone access may be used by Mattermost plugins, such as Jitsi video conferencing.
|
||||
NSCameraUsageDescription: Camera access may be used by Mattermost plugins, such as Jitsi video conferencing.
|
||||
NSFocusStatusUsageDescription: Focus status is used by Mattermost to determine whether to send notifications or not.
|
||||
LSFileQuarantineEnabled: true
|
||||
notarize:
|
||||
teamId: UQ8HT4Q2XM
|
||||
mas:
|
||||
hardenedRuntime: false
|
||||
entitlements: ./resources/mac/entitlements.mas.plist
|
||||
entitlementsInherit: ./resources/mac/entitlements.mas.inherit.plist
|
||||
entitlementsLoginHelper: ./resources/mac/entitlements.mas.inherit.plist
|
||||
provisioningProfile: ./mas.provisionprofile
|
||||
extendInfo:
|
||||
ITSAppUsesNonExemptEncryption: false
|
||||
NSUserActivityTypes:
|
||||
- INSendMessageIntent
|
||||
singleArchFiles: '*'
|
||||
masDev:
|
||||
provisioningProfile: ./dev.provisionprofile
|
||||
dmg:
|
||||
background: src/assets/osx/DMG_BG.png
|
||||
contents:
|
||||
- x: 135
|
||||
'y': 165
|
||||
- x: 407
|
||||
'y': 165
|
||||
type: link
|
||||
path: /Applications
|
||||
iconSize: 120
|
||||
iconTextSize: 14
|
||||
window:
|
||||
height: 380
|
||||
squirrelWindows:
|
||||
iconUrl: file://src/assets/icon.ico
|
||||
artifactName: ${version}/${name}-setup-${version}-${arch}.${ext}
|
||||
win:
|
||||
target:
|
||||
- nsis
|
||||
- zip
|
||||
- msi
|
||||
extraFiles:
|
||||
- filter:
|
||||
- LICENSE.txt
|
||||
- NOTICE.txt
|
||||
- from: resources/windows/gpo
|
||||
to: gpo
|
||||
signDlls: true
|
||||
publisherName: CN="aaron", O="buds inc.", L=turner somewhere, S=oregon, C=US
|
||||
nsis:
|
||||
artifactName: ${version}/${name}-setup-${version}-win.${ext}
|
||||
packElevateHelper: false
|
||||
uninstallDisplayName: ${productName}
|
||||
include: scripts/installer.nsh
|
||||
warningsAsErrors: false
|
||||
msi:
|
||||
additionalWixArgs:
|
||||
- '-ext'
|
||||
- WixUtilExtension
|
||||
rpm:
|
||||
fpm:
|
||||
- '--rpm-rpmbuild-define'
|
||||
- _build_id_links none
|
||||
electronVersion: 31.6.0
|
Loading…
Reference in a new issue