mirror of
https://github.com/bitwarden/browser.git
synced 2024-11-23 11:56:00 +01:00
changing out snap build script
This commit is contained in:
parent
7669b654ce
commit
20dcfe8ad3
35
.github/workflows/build.yml
vendored
35
.github/workflows/build.yml
vendored
@ -96,15 +96,12 @@ jobs:
|
||||
- name: Package Chocolatey
|
||||
shell: pwsh
|
||||
run: |
|
||||
#.\scripts\choco-pack.ps1 # DO NOT USE PUSH SWITCH!
|
||||
Copy-Item -Path stores\chocolatey -Destination dist\chocolatey -Recurse
|
||||
Copy-Item dist\windows\bw.exe -Destination dist\chocolatey\tools
|
||||
Copy-Item LICENSE.txt -Destination dist\chocolatey\tools
|
||||
|
||||
choco pack dist\chocolatey\bitwarden-cli.nuspec --version ${{ env.PACKAGE_VERSION }} --out dist\chocolatey
|
||||
|
||||
Get-ChildItem
|
||||
|
||||
- name: Zip
|
||||
shell: cmd
|
||||
run: |
|
||||
@ -221,15 +218,20 @@ jobs:
|
||||
name: Publish Snap
|
||||
runs-on: ubuntu-latest
|
||||
needs: build
|
||||
if: github.event_name == 'release'
|
||||
#if: github.event_name == 'release'
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Set PACKAGE_VERSION
|
||||
run: |
|
||||
$env:pkgVersion = (Get-Content -Raw -Path .\package.json | ConvertFrom-Json).version
|
||||
echo "PACKAGE_VERSION=$env:pkgVersion" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
|
||||
|
||||
- name: Install Snapcraft
|
||||
uses: samuelmeuli/action-snapcraft@v1
|
||||
with:
|
||||
snapcraft_token: ${{ secrets.SNAP_TOKEN }}
|
||||
#with:
|
||||
# snapcraft_token: ${{ secrets.SNAP_TOKEN }}
|
||||
|
||||
- name: Print environment
|
||||
run: |
|
||||
@ -244,7 +246,16 @@ jobs:
|
||||
- name: Install Snap
|
||||
shell: pwsh
|
||||
run: |
|
||||
./scripts/snap-build.ps1 -version $env:PACKAGE_VERSION
|
||||
#./scripts/snap-build.ps1 -version $env:PACKAGE_VERSION
|
||||
Copy-Item -Path stores\snap -Destination dist\snap
|
||||
(Get-Content snap\snapcraft.yaml).replace('__version__', ${{ env.PACKAGE_VERSION }}) | Set-Content snap\snapcraft.yaml
|
||||
|
||||
cd dist\snap
|
||||
Get-ChildItem
|
||||
snapcraft
|
||||
cd ..\..
|
||||
Get-ChildItem
|
||||
|
||||
snap install ./dist/snap/bw*.snap --dangerous
|
||||
|
||||
- name: Test Snap
|
||||
@ -261,11 +272,11 @@ jobs:
|
||||
snap remove bw
|
||||
./scripts/snap-update.ps1
|
||||
|
||||
- name: Publish
|
||||
shell: pwsh
|
||||
run: |
|
||||
echo "<stub for publishing snap to github release>"
|
||||
echo "./dist/snap/bw_${PACKAGE_VERSION}_amd64.snap"
|
||||
- name: Publish linux checksum to GitHub
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: bw_${{ env.PACKAGE_VERSION }}_amd64.snap
|
||||
path: ./dist/snap/bw_${{ env.PACKAGE_VERSION }}_amd64.snap
|
||||
|
||||
- name: Snap Logout
|
||||
run: snapcraft logout
|
||||
|
Loading…
Reference in New Issue
Block a user