1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-25 04:33:34 +00:00

Update pipelines (#936)

* Update workflows for consistency

* Update pipelines

- Trigger deploy workflow manually
- Publish release draft at the end of deploy workflow

* Enable artifact uploads for all branches and fail if no asset is found during upload

* Add if statements back in for MacOS

* Change Build application (dev) step
This commit is contained in:
Vince Grassia
2021-06-01 17:14:02 -04:00
committed by GitHub
parent 60f3d5d33e
commit 163351c3e7
3 changed files with 53 additions and 32 deletions

View File

@@ -6,13 +6,10 @@ on:
release_tag_name_input:
description: "Release Tag Name <X.X.X>"
required: true
release:
types:
- published
jobs:
setup:
name: Setup
runs-on: ubuntu-latest
outputs:
package_version: ${{ steps.create_tags.outputs.package_version }}
@@ -52,7 +49,6 @@ jobs:
env:
RELEASE_TAG_NAME_INPUT: ${{ github.event.inputs.release_tag_name_input }}
snap:
name: Deploy Snap
runs-on: ubuntu-latest
@@ -69,10 +65,10 @@ jobs:
with:
snapcraft_token: ${{ secrets.SNAP_TOKEN }}
- name: setup
- name: Setup
run: mkdir dist
- name: get snap package
- name: Get snap package
uses: Xotl/cool-github-releases@16c58a5863d6ba9944f63ca8bb78bb3249ce1d81
with:
mode: download
@@ -80,7 +76,7 @@ jobs:
assets: bitwarden_${{ env.PKG_VERSION }}_amd64.snap|./dist/bitwarden_${{ env.PKG_VERSION }}_amd64.snap
github_token: ${{ secrets.GITHUB_TOKEN }}
- name: test
- name: Test
run: ls -alht dist
- name: Deploy to Snap Store
@@ -88,7 +84,6 @@ jobs:
snapcraft upload dist/bitwarden_${{ env.PKG_VERSION }}_amd64.snap --release stable
snapcraft logout
choco:
name: Deploy Choco
runs-on: windows-latest
@@ -113,7 +108,7 @@ jobs:
env:
CHOCO_API_KEY: ${{ secrets.CHOCO_API_KEY }}
- name: make dist dir
- name: Make dist dir
shell: pwsh
run: New-Item -ItemType directory -Path ./dist
@@ -131,8 +126,8 @@ jobs:
cd dist
choco push
macos:
name: Deploy MacOS
runs-on: macos-latest
needs: setup
env:
@@ -142,10 +137,10 @@ jobs:
- name: Checkout repo
uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f
- name: make target directory
- name: Make target directory
run: mkdir -p dist/mas-universal
- name: Get mac release asset
- name: Get Mac release asset
uses: Xotl/cool-github-releases@16c58a5863d6ba9944f63ca8bb78bb3249ce1d81
with:
mode: download
@@ -158,3 +153,24 @@ jobs:
env:
APPLE_ID_USERNAME: ${{ secrets.APPLE_ID_USERNAME }}
APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
publish:
name: Publish Release
runs-on: ubuntu-latest
needs:
- setup
- snap
- choco
- macos
env:
RELEASE_VERSION: ${{ needs.setup.outputs.release_version }}
TAG_VERSION: ${{ needs.setup.outputs.tag_version }}
steps:
- name: Publish release
run: |
hub release edit \
--draft=false \
--message "" \
$TAG_VERSION
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}