Skip to content

chore(deps): update all non-major dependencies #2114

chore(deps): update all non-major dependencies

chore(deps): update all non-major dependencies #2114

Workflow file for this run

# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
name: Build
on: [push]
jobs:
lint:
name: 'Lint'
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
submodules: true
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: '16'
- uses: actions/cache@v3
with:
path: '**/node_modules'
key: linter-node_modules-${{hashFiles('**/package-lock.json') }}
- name: Install dependencies
env:
JOBS: 'max'
run: npm install
- name: Run linter
run: npm run lint
build:
name: Build (${{ matrix.os }} - ${{ matrix.arch }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
# Build for supported platforms
# https://github.com/electron/electron-packager/blob/ebcbd439ff3e0f6f92fa880ff28a8670a9bcf2ab/src/targets.js#L9
include:
- os: ubuntu-20.04
arch: arm64
- os: ubuntu-20.04
arch: x64
- os: macOS-11
arch: arm64
openssl_dir: '/tmp/openssl@1.1/1.1.1l_1'
- os: macOS-11
arch: x64
openssl_dir: '/usr/local/opt/openssl@1.1'
- os: windows-2019
arch: x64
openssl_dir: 'C:\Program Files\OpenSSL-Win64\'
# - os: ubuntu-20.04
# arch: armv7l
# - os: windows-2019
# arch: arm64
# openssl_dir: 'C:\Program Files\OpenSSL-Win64\'
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
submodules: true
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: '16'
- uses: actions/cache@v3
with:
path: '**/node_modules'
key: ${{ matrix.os }}-${{ matrix.arch }}-node_modules-${{hashFiles('**/package-lock.json') }}
- name: Install Build dependencies (macOS-arm64)
if: |
matrix.os == 'macOS-11'
&& matrix.arch == 'arm64'
run: |
curl -L -H "Authorization: Bearer QQ==" -o /tmp/openssl-1.1.1l_1-arm64.tar.gz https://ghcr.io/v2/homebrew/core/openssl/1.1/blobs/sha256:8f5b0bee61c1570b9f0fc0a21d6c322e904ae7975bdaada5787451d18e9677a6
tar -xvf /tmp/openssl-1.1.1l_1-arm64.tar.gz -C /tmp
- name: Install Build dependencies (Windows)
if: matrix.os == 'windows-2019'
run: choco install openssl
- name: Install Build dependencies (Ubuntu)
if: matrix.os == 'ubuntu-20.04'
run: |
sudo apt update
sudo apt install libkrb5-dev
- name: Install dependencies
env:
JOBS: 'max'
npm_config_openssl_dir: ${{ matrix.openssl_dir }}
run: |
npm install
- name: Rebuild native modules
env:
JOBS: 'max'
npm_config_openssl_dir: ${{ matrix.openssl_dir }}
run: |
npm run rebuild:native-modules -- --arch=${{ matrix.arch }}
npm run prepare:nodegit
- name: Load Developer Certificates (macOS)
if: |
startsWith(github.ref, 'refs/tags/')
&& matrix.os == 'macOS-11'
env:
MACOS_CERT_P12: ${{ secrets.MACOS_CERT_P12 }}
MACOS_CERT_PASSWORD: ${{ secrets.MACOS_CERT_PASSWORD }}
run:
chmod +x scripts/setupMacOSCertificates.sh && ./scripts/setupMacOSCertificates.sh
- name: Compile and Sign
if: startsWith(github.ref, 'refs/tags/')
env:
npm_config_openssl_dir: ${{ matrix.openssl_dir }}
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
MACOS_CERT_P12: ${{ secrets.MACOS_CERT_P12 }}
MACOS_CERT_PASSWORD: ${{ secrets.MACOS_CERT_PASSWORD }}
GMAIL_OAUTH_CLIENT_ID: ${{ secrets.GMAIL_OAUTH_CLIENT_ID }}
GMAIL_OAUTH_CLIENT_SECRET: ${{ secrets.GMAIL_OAUTH_CLIENT_SECRET }}
run:
npm run make -- --arch=${{ matrix.arch }}
- name: Compile
if: startsWith(github.ref, 'refs/tags/') == false
env:
npm_config_openssl_dir: ${{ matrix.openssl_dir }}
GMAIL_OAUTH_CLIENT_ID: ${{ secrets.GMAIL_OAUTH_CLIENT_ID }}
GMAIL_OAUTH_CLIENT_SECRET: ${{ secrets.GMAIL_OAUTH_CLIENT_SECRET }}
run: npm run make -- --arch=${{ matrix.arch }}
- name: Test
if: |
matrix.os != 'ubuntu-20.04'
&& matrix.arch == 'x64'
&& matrix.os != 'macOS-11'
&& matrix.os != 'windows-2019'
run: npm run test
- name: Test (Ubuntu)
if: |
matrix.os == 'ubuntu-20.04'
&& matrix.arch == 'x64'
run: xvfb-run --auto-servernum -- npm test
- name: Upload artifacts
if: ${{ always() }}
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.os }}-${{ matrix.arch }}
path: |
out/make
test/output
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: "out/make/**"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}