mirror of
https://github.com/bitwarden/browser
synced 2025-12-16 08:13:42 +00:00
removing the testing code from the pipelines
This commit is contained in:
132
.github/workflows/build-and-sign.yml
vendored
132
.github/workflows/build-and-sign.yml
vendored
@@ -1,132 +0,0 @@
|
|||||||
name: Build & Sign
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches-ignore:
|
|
||||||
- 'l10n_master'
|
|
||||||
- 'gh-pages'
|
|
||||||
release:
|
|
||||||
types:
|
|
||||||
- published
|
|
||||||
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
windows:
|
|
||||||
runs-on: windows-latest
|
|
||||||
environment: prod
|
|
||||||
steps:
|
|
||||||
- name: Set up dotnet
|
|
||||||
uses: actions/setup-dotnet@v1
|
|
||||||
with:
|
|
||||||
dotnet-version: "3.1.x"
|
|
||||||
|
|
||||||
- name: Set up Node
|
|
||||||
uses: actions/setup-node@v1
|
|
||||||
with:
|
|
||||||
node-version: '10.x'
|
|
||||||
|
|
||||||
- name: Set Node options
|
|
||||||
run: echo "NODE_OPTIONS=--max_old_space_size=4096" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
|
|
||||||
shell: pwsh
|
|
||||||
|
|
||||||
- name: Print environment
|
|
||||||
run: |
|
|
||||||
node --version
|
|
||||||
npm --version
|
|
||||||
dotnet --version
|
|
||||||
|
|
||||||
- name: Install AST
|
|
||||||
shell: pwsh
|
|
||||||
run: |
|
|
||||||
cd $HOME
|
|
||||||
|
|
||||||
git clone https://github.com/vcsjones/AzureSignTool.git
|
|
||||||
cd AzureSignTool
|
|
||||||
$latest_head = $(git rev-parse HEAD)[0..9] -join ""
|
|
||||||
$latest_version = "0.0.0-g$latest_head"
|
|
||||||
|
|
||||||
Write-Host "--------"
|
|
||||||
Write-Host "git commit - $(git rev-parse HEAD)"
|
|
||||||
Write-Host "latest_head - $latest_head"
|
|
||||||
Write-Host "PACKAGE VERSION TO BUILD - $latest_version"
|
|
||||||
Write-Host "--------"
|
|
||||||
|
|
||||||
dotnet restore
|
|
||||||
dotnet pack --output ./nupkg
|
|
||||||
dotnet tool install --global --ignore-failed-sources --add-source ./nupkg --version $latest_version azuresigntool
|
|
||||||
|
|
||||||
cd $HOME
|
|
||||||
|
|
||||||
- name: Checkout repo
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
|
|
||||||
- name: Load package version
|
|
||||||
run: ./.github/scripts/load-version.ps1
|
|
||||||
shell: pwsh
|
|
||||||
|
|
||||||
- name: Install Node dependencies
|
|
||||||
run: npm install
|
|
||||||
|
|
||||||
- name: Run linter
|
|
||||||
run: npm run lint
|
|
||||||
|
|
||||||
- name: Build application
|
|
||||||
run: npm run build
|
|
||||||
|
|
||||||
- name: Build & Sign
|
|
||||||
run: |
|
|
||||||
npm run build
|
|
||||||
npm run pack:win
|
|
||||||
env:
|
|
||||||
ELECTRON_BUILDER_SIGN: 1
|
|
||||||
SIGNING_VAULT_URL: ${{ secrets.SIGNING_VAULT_URL }}
|
|
||||||
SIGNING_CLIENT_ID: ${{ secrets.SIGNING_CLIENT_ID }}
|
|
||||||
SIGNING_TENANT_ID: ${{ secrets.SIGNING_TENANT_ID }}
|
|
||||||
SIGNING_CLIENT_SECRET: ${{ secrets.SIGNING_CLIENT_SECRET }}
|
|
||||||
SIGNING_CERT_NAME: ${{ secrets.SIGNING_CERT_NAME }}
|
|
||||||
|
|
||||||
- name: List Dist
|
|
||||||
run: dir ./dist
|
|
||||||
|
|
||||||
- name: Upload signed portable exe artifact
|
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
|
||||||
uses: actions/upload-artifact@v2
|
|
||||||
with:
|
|
||||||
name: Bitwarden-Portable-${{ env.PACKAGE_VERSION }}-signed.exe
|
|
||||||
path: ./dist/Bitwarden-Portable-${{ env.PACKAGE_VERSION }}.exe
|
|
||||||
|
|
||||||
- name: Upload signed installer exe artifact
|
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
|
||||||
uses: actions/upload-artifact@v2
|
|
||||||
with:
|
|
||||||
name: Bitwarden-Installer-${{ env.PACKAGE_VERSION }}-signed.exe
|
|
||||||
path: ./dist/nsis-web/Bitwarden-Installer-${{ env.PACKAGE_VERSION }}.exe
|
|
||||||
|
|
||||||
- name: Upload appx ia32 artifact (not signed)
|
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
|
||||||
uses: actions/upload-artifact@v2
|
|
||||||
with:
|
|
||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}-ia32.appx
|
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-ia32.appx
|
|
||||||
|
|
||||||
- name: Upload appx x64 artifact (not signed)
|
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
|
||||||
uses: actions/upload-artifact@v2
|
|
||||||
with:
|
|
||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x64.appx
|
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x64.appx
|
|
||||||
|
|
||||||
- name: Upload release assets
|
|
||||||
if: github.event_name == 'release'
|
|
||||||
run: |
|
|
||||||
hub release edit `
|
|
||||||
-a ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-ia32.appx `
|
|
||||||
-a ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x64.appx `
|
|
||||||
-a ./dist/Bitwarden-Portable-${{ env.PACKAGE_VERSION }}.exe `
|
|
||||||
-a ./dist/nsis-web/Bitwarden-Installer-${{ env.PACKAGE_VERSION }}.exe `
|
|
||||||
-m "$($env:RELEASE_TAG_NAME.TrimStart('v'))" `
|
|
||||||
$env:RELEASE_TAG_NAME
|
|
||||||
shell: pwsh
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
RELEASE_TAG_NAME: ${{ github.event.release.tag_name }}
|
|
||||||
130
.github/workflows/build.yml
vendored
130
.github/workflows/build.yml
vendored
@@ -5,10 +5,6 @@ on:
|
|||||||
branches-ignore:
|
branches-ignore:
|
||||||
- 'l10n_master'
|
- 'l10n_master'
|
||||||
- 'gh-pages'
|
- 'gh-pages'
|
||||||
release:
|
|
||||||
types:
|
|
||||||
#- published
|
|
||||||
- created
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
@@ -44,13 +40,9 @@ jobs:
|
|||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get -y install pkg-config libxss-dev libsecret-1-dev rpm
|
sudo apt-get -y install pkg-config libxss-dev libsecret-1-dev rpm
|
||||||
|
|
||||||
#- name: Set up snap
|
- name: Set up snap
|
||||||
# if: github.event_name == 'release'
|
run: |
|
||||||
# run: |
|
sudo snap install snapcraft --classic
|
||||||
# sudo snap install snapcraft --classic
|
|
||||||
# echo "$SNAP_TOKEN" | snapcraft login --with -
|
|
||||||
# env:
|
|
||||||
# SNAP_TOKEN: ${{ secrets.SNAP_TOKEN }}
|
|
||||||
|
|
||||||
- name: Print environment
|
- name: Print environment
|
||||||
run: |
|
run: |
|
||||||
@@ -76,50 +68,43 @@ jobs:
|
|||||||
run: npm run dist:lin
|
run: npm run dist:lin
|
||||||
|
|
||||||
- name: Upload .deb artifact
|
- name: Upload .deb artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}-amd64.deb
|
name: Bitwarden-${{ env.PACKAGE_VERSION }}-amd64.deb
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-amd64.deb
|
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-amd64.deb
|
||||||
|
|
||||||
- name: Upload .rpm artifact
|
- name: Upload .rpm artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.rpm
|
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.rpm
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.rpm
|
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.rpm
|
||||||
|
|
||||||
- name: Upload .freebsd artifact
|
- name: Upload .freebsd artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x64.freebsd
|
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x64.freebsd
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x64.freebsd
|
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x64.freebsd
|
||||||
|
|
||||||
- name: Upload .snap artifact
|
- name: Upload .snap artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: bitwarden_${{ env.PACKAGE_VERSION }}_amd64.snap
|
name: bitwarden_${{ env.PACKAGE_VERSION }}_amd64.snap
|
||||||
path: ./dist/bitwarden_${{ env.PACKAGE_VERSION }}_amd64.snap
|
path: ./dist/bitwarden_${{ env.PACKAGE_VERSION }}_amd64.snap
|
||||||
|
|
||||||
- name: Upload .AppImage artifact
|
- name: Upload .AppImage artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.AppImage
|
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.AppImage
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.AppImage
|
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.AppImage
|
||||||
|
|
||||||
#- name: Deploy to Snap Store
|
|
||||||
# if: github.event_name == 'release'
|
|
||||||
# run: |
|
|
||||||
# ./scripts/snap-update.ps1 -version $env:PACKAGE_VERSION
|
|
||||||
# snapcraft logout
|
|
||||||
# shell: pwsh
|
|
||||||
|
|
||||||
windows:
|
windows:
|
||||||
runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
environment: prod
|
|
||||||
steps:
|
steps:
|
||||||
- name: Set up dotnet
|
- name: Set up dotnet
|
||||||
uses: actions/setup-dotnet@v1
|
uses: actions/setup-dotnet@v1
|
||||||
@@ -155,14 +140,10 @@ jobs:
|
|||||||
dotnet pack --output ./nupkg
|
dotnet pack --output ./nupkg
|
||||||
dotnet tool install --global --ignore-failed-sources --add-source ./nupkg --version $latest_version azuresigntool
|
dotnet tool install --global --ignore-failed-sources --add-source ./nupkg --version $latest_version azuresigntool
|
||||||
|
|
||||||
#- name: Set up environment
|
- name: Set up environment
|
||||||
# if: false github.event_name == 'release'
|
shell: pwsh
|
||||||
# shell: pwsh
|
run: |
|
||||||
# run: |
|
choco install checksum --no-progress
|
||||||
# choco install checksum --no-progress
|
|
||||||
# choco apikey --key $env:CHOCO_API_KEY --source https://push.chocolatey.org/
|
|
||||||
# env:
|
|
||||||
# CHOCO_API_KEY: ${{ secrets.CHOCO_API_KEY }}
|
|
||||||
|
|
||||||
- name: Print environment
|
- name: Print environment
|
||||||
run: |
|
run: |
|
||||||
@@ -184,7 +165,6 @@ jobs:
|
|||||||
run: npm run lint
|
run: npm run lint
|
||||||
|
|
||||||
- name: Build & Sign (dev)
|
- name: Build & Sign (dev)
|
||||||
if: github.event_name != 'release'
|
|
||||||
run: |
|
run: |
|
||||||
npm run build
|
npm run build
|
||||||
npm run pack:win
|
npm run pack:win
|
||||||
@@ -196,18 +176,6 @@ jobs:
|
|||||||
SIGNING_CLIENT_SECRET: ${{ secrets.SIGNING_CLIENT_SECRET }}
|
SIGNING_CLIENT_SECRET: ${{ secrets.SIGNING_CLIENT_SECRET }}
|
||||||
SIGNING_CERT_NAME: ${{ secrets.SIGNING_CERT_NAME }}
|
SIGNING_CERT_NAME: ${{ secrets.SIGNING_CERT_NAME }}
|
||||||
|
|
||||||
#- name: Build, Sign & Release
|
|
||||||
# if: github.event_name == 'release'
|
|
||||||
# run: npm run publish:win
|
|
||||||
# env:
|
|
||||||
# ELECTRON_BUILDER_SIGN: 1
|
|
||||||
# SIGNING_VAULT_URL: ${{ secrets.SIGNING_VAULT_URL }}
|
|
||||||
# SIGNING_CLIENT_ID: ${{ secrets.SIGNING_CLIENT_ID }}
|
|
||||||
# SIGNING_TENANT_ID: ${{ secrets.SIGNING_TENANT_ID }}
|
|
||||||
# SIGNING_CLIENT_SECRET: ${{ secrets.SIGNING_CLIENT_SECRET }}
|
|
||||||
# SIGNING_CERT_NAME: ${{ secrets.SIGNING_CERT_NAME }}
|
|
||||||
# GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
|
|
||||||
|
|
||||||
- name: Rename appx files for store
|
- name: Rename appx files for store
|
||||||
shell: pwsh
|
shell: pwsh
|
||||||
run: |
|
run: |
|
||||||
@@ -217,58 +185,33 @@ jobs:
|
|||||||
-Destination "./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x64-store.appx"
|
-Destination "./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x64-store.appx"
|
||||||
|
|
||||||
- name: Upload portable exe artifact
|
- name: Upload portable exe artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: Bitwarden-Portable-${{ env.PACKAGE_VERSION }}.exe
|
name: Bitwarden-Portable-${{ env.PACKAGE_VERSION }}.exe
|
||||||
path: ./dist/Bitwarden-Portable-${{ env.PACKAGE_VERSION }}.exe
|
path: ./dist/Bitwarden-Portable-${{ env.PACKAGE_VERSION }}.exe
|
||||||
|
|
||||||
- name: Upload installer exe artifact
|
- name: Upload installer exe artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: Bitwarden-Installer-${{ env.PACKAGE_VERSION }}.exe
|
name: Bitwarden-Installer-${{ env.PACKAGE_VERSION }}.exe
|
||||||
path: ./dist/nsis-web/Bitwarden-Installer-${{ env.PACKAGE_VERSION }}.exe
|
path: ./dist/nsis-web/Bitwarden-Installer-${{ env.PACKAGE_VERSION }}.exe
|
||||||
|
|
||||||
- name: Upload store appx ia32 artifact
|
- name: Upload store appx ia32 artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}-ia32-store.appx
|
name: Bitwarden-${{ env.PACKAGE_VERSION }}-ia32-store.appx
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-ia32-store.appx
|
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-ia32-store.appx
|
||||||
|
|
||||||
- name: Upload store appx x64 artifact
|
- name: Upload store appx x64 artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x64-store.appx
|
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x64-store.appx
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x64-store.appx
|
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x64-store.appx
|
||||||
|
|
||||||
#- name: Deploy to Chocolatey
|
|
||||||
# if: github.event_name == 'release'
|
|
||||||
# run: ./scripts/choco-update.ps1 -version $env:PACKAGE_VERSION
|
|
||||||
# shell: pwsh
|
|
||||||
|
|
||||||
#- name: Upload Chocolatey nupkg artifact
|
|
||||||
# if: github.event_name == 'release'
|
|
||||||
# uses: actions/upload-artifact@v2
|
|
||||||
# with:
|
|
||||||
# name: bitwarden.${{ env.PACKAGE_VERSION }}.nupkg
|
|
||||||
# path: ./dist/chocolatey/bitwarden.${{ env.PACKAGE_VERSION }}.nupkg
|
|
||||||
|
|
||||||
#- name: Upload release assets
|
|
||||||
# if: github.event_name == 'release'
|
|
||||||
# run: |
|
|
||||||
# hub release edit `
|
|
||||||
# -a ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-ia32-store.appx `
|
|
||||||
# -a ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x64-store.appx `
|
|
||||||
# -m "$($env:RELEASE_TAG_NAME.TrimStart('v'))" `
|
|
||||||
# $env:RELEASE_TAG_NAME
|
|
||||||
# shell: pwsh
|
|
||||||
# env:
|
|
||||||
# GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
|
|
||||||
# RELEASE_TAG_NAME: ${{ github.event.release.tag_name }}
|
|
||||||
|
|
||||||
macos:
|
macos:
|
||||||
runs-on: macos-latest
|
runs-on: macos-latest
|
||||||
steps:
|
steps:
|
||||||
@@ -330,86 +273,67 @@ jobs:
|
|||||||
run: npm run lint
|
run: npm run lint
|
||||||
|
|
||||||
- name: Create Safari directory
|
- name: Create Safari directory
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
shell: pwsh
|
shell: pwsh
|
||||||
run: New-Item ./dist-safari -ItemType Directory -ea 0
|
run: New-Item ./dist-safari -ItemType Directory -ea 0
|
||||||
|
|
||||||
- name: Checkout browser extension
|
- name: Checkout browser extension
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
repository: 'bitwarden/browser'
|
repository: 'bitwarden/browser'
|
||||||
path: 'dist-safari/browser'
|
path: 'dist-safari/browser'
|
||||||
|
|
||||||
- name: Build Safari extension
|
- name: Build Safari extension
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
shell: pwsh
|
shell: pwsh
|
||||||
run: ./scripts/safari-build.ps1 -skipcheckout -skipoutcopy
|
run: ./scripts/safari-build.ps1 -skipcheckout -skipoutcopy
|
||||||
|
|
||||||
- name: Load Safari extension for .dmg
|
- name: Load Safari extension for .dmg
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
shell: pwsh
|
shell: pwsh
|
||||||
run: ./scripts/safari-build.ps1 -copyonly
|
run: ./scripts/safari-build.ps1 -copyonly
|
||||||
|
|
||||||
- name: Build application (dev)
|
- name: Build application (dev)
|
||||||
if: github.ref != 'refs/heads/master' && github.event_name != 'release'
|
if: github.ref != 'refs/heads/master'
|
||||||
run: npm run build
|
run: npm run build
|
||||||
|
|
||||||
- name: Build application (dist)
|
- name: Build application (dist)
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
run: npm run dist:mac
|
run: npm run dist:mac
|
||||||
env:
|
env:
|
||||||
APPLE_ID_USERNAME: ${{ secrets.APPLE_ID_USERNAME }}
|
APPLE_ID_USERNAME: ${{ secrets.APPLE_ID_USERNAME }}
|
||||||
APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
|
APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
|
||||||
|
|
||||||
- name: Upload .zip artifact
|
- name: Upload .zip artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}-mac.zip
|
name: Bitwarden-${{ env.PACKAGE_VERSION }}-mac.zip
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-mac.zip
|
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-mac.zip
|
||||||
|
|
||||||
- name: Upload .dmg artifact
|
- name: Upload .dmg artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}.dmg
|
name: Bitwarden-${{ env.PACKAGE_VERSION }}.dmg
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}.dmg
|
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}.dmg
|
||||||
|
|
||||||
- name: Load Safari extension for App Store
|
- name: Load Safari extension for App Store
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
shell: pwsh
|
shell: pwsh
|
||||||
run: ./scripts/safari-build.ps1 -mas -copyonly
|
run: ./scripts/safari-build.ps1 -mas -copyonly
|
||||||
|
|
||||||
- name: Build application for App Store
|
- name: Build application for App Store
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
run: npm run dist:mac:mas
|
run: npm run dist:mac:mas
|
||||||
env:
|
env:
|
||||||
APPLE_ID_USERNAME: ${{ secrets.APPLE_ID_USERNAME }}
|
APPLE_ID_USERNAME: ${{ secrets.APPLE_ID_USERNAME }}
|
||||||
APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
|
APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
|
||||||
|
|
||||||
- name: Upload .pkg artifact
|
- name: Upload .pkg artifact
|
||||||
if: github.ref == 'refs/heads/master' || github.event_name == 'release'
|
if: github.ref == 'refs/heads/master'
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}.pkg
|
name: Bitwarden-${{ env.PACKAGE_VERSION }}.pkg
|
||||||
path: ./dist/mas/Bitwarden-${{ env.PACKAGE_VERSION }}.pkg
|
path: ./dist/mas/Bitwarden-${{ env.PACKAGE_VERSION }}.pkg
|
||||||
|
|
||||||
#- name: Deploy to App Store
|
|
||||||
# if: github.event_name == 'release'
|
|
||||||
# run: npm run upload:mas
|
|
||||||
# env:
|
|
||||||
# APPLE_ID_USERNAME: ${{ secrets.APPLE_ID_USERNAME }}
|
|
||||||
# APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
|
|
||||||
|
|
||||||
#- name: Upload release assets
|
|
||||||
# if: github.event_name == 'release'
|
|
||||||
# run: |
|
|
||||||
# hub release edit `
|
|
||||||
# -a ./dist/mas/Bitwarden-${{ env.PACKAGE_VERSION }}.pkg `
|
|
||||||
# -m "$($env:RELEASE_TAG_NAME.TrimStart('v'))" `
|
|
||||||
# $env:RELEASE_TAG_NAME
|
|
||||||
# shell: pwsh
|
|
||||||
# env:
|
|
||||||
# GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
|
|
||||||
# RELEASE_TAG_NAME: ${{ github.event.release.tag_name }}
|
|
||||||
|
|||||||
47
.github/workflows/release.yml
vendored
47
.github/workflows/release.yml
vendored
@@ -44,9 +44,9 @@ jobs:
|
|||||||
- name: Set up snap
|
- name: Set up snap
|
||||||
run: |
|
run: |
|
||||||
sudo snap install snapcraft --classic
|
sudo snap install snapcraft --classic
|
||||||
# echo "$SNAP_TOKEN" | snapcraft login --with -
|
echo "$SNAP_TOKEN" | snapcraft login --with -
|
||||||
#env:
|
env:
|
||||||
# SNAP_TOKEN: ${{ secrets.SNAP_TOKEN }}
|
SNAP_TOKEN: ${{ secrets.SNAP_TOKEN }}
|
||||||
|
|
||||||
- name: Print environment
|
- name: Print environment
|
||||||
run: |
|
run: |
|
||||||
@@ -101,15 +101,14 @@ jobs:
|
|||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.AppImage
|
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.AppImage
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.AppImage
|
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x86_64.AppImage
|
||||||
|
|
||||||
#- name: Deploy to Snap Store
|
- name: Deploy to Snap Store
|
||||||
# run: |
|
run: |
|
||||||
# ./scripts/snap-update.ps1 -version $env:PACKAGE_VERSION
|
./scripts/snap-update.ps1 -version $env:PACKAGE_VERSION
|
||||||
# snapcraft logout
|
snapcraft logout
|
||||||
# shell: pwsh
|
shell: pwsh
|
||||||
|
|
||||||
windows:
|
windows:
|
||||||
runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
environment: prod
|
|
||||||
steps:
|
steps:
|
||||||
- name: Set up dotnet
|
- name: Set up dotnet
|
||||||
uses: actions/setup-dotnet@v1
|
uses: actions/setup-dotnet@v1
|
||||||
@@ -145,13 +144,13 @@ jobs:
|
|||||||
dotnet pack --output ./nupkg
|
dotnet pack --output ./nupkg
|
||||||
dotnet tool install --global --ignore-failed-sources --add-source ./nupkg --version $latest_version azuresigntool
|
dotnet tool install --global --ignore-failed-sources --add-source ./nupkg --version $latest_version azuresigntool
|
||||||
|
|
||||||
#- name: Set up environment
|
- name: Set up environment
|
||||||
# shell: pwsh
|
shell: pwsh
|
||||||
# run: |
|
run: |
|
||||||
# choco install checksum --no-progress
|
choco install checksum --no-progress
|
||||||
# choco apikey --key $env:CHOCO_API_KEY --source https://push.chocolatey.org/
|
choco apikey --key $env:CHOCO_API_KEY --source https://push.chocolatey.org/
|
||||||
# env:
|
env:
|
||||||
# CHOCO_API_KEY: ${{ secrets.CHOCO_API_KEY }}
|
CHOCO_API_KEY: ${{ secrets.CHOCO_API_KEY }}
|
||||||
|
|
||||||
- name: Print environment
|
- name: Print environment
|
||||||
run: |
|
run: |
|
||||||
@@ -215,15 +214,15 @@ jobs:
|
|||||||
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x64-store.appx
|
name: Bitwarden-${{ env.PACKAGE_VERSION }}-x64-store.appx
|
||||||
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x64-store.appx
|
path: ./dist/Bitwarden-${{ env.PACKAGE_VERSION }}-x64-store.appx
|
||||||
|
|
||||||
#- name: Deploy to Chocolatey
|
- name: Deploy to Chocolatey
|
||||||
# run: ./scripts/choco-update.ps1 -version $env:PACKAGE_VERSION
|
run: ./scripts/choco-update.ps1 -version $env:PACKAGE_VERSION
|
||||||
# shell: pwsh
|
shell: pwsh
|
||||||
|
|
||||||
#- name: Upload Chocolatey nupkg artifact
|
- name: Upload Chocolatey nupkg artifact
|
||||||
# uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
# with:
|
with:
|
||||||
# name: bitwarden.${{ env.PACKAGE_VERSION }}.nupkg
|
name: bitwarden.${{ env.PACKAGE_VERSION }}.nupkg
|
||||||
# path: ./dist/chocolatey/bitwarden.${{ env.PACKAGE_VERSION }}.nupkg
|
path: ./dist/chocolatey/bitwarden.${{ env.PACKAGE_VERSION }}.nupkg
|
||||||
|
|
||||||
- name: Upload release assets
|
- name: Upload release assets
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
Reference in New Issue
Block a user