Skip to content

Commit

Permalink
Try fromJSON hack
Browse files Browse the repository at this point in the history
  • Loading branch information
abitrolly committed Jun 23, 2023
1 parent 8856517 commit c49f437
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/snap.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Build default branch and PRs, publish only from default.
# Needs `STORE_LOGIN` configured https://github.com/snapcore/action-publish#store-login
# Change channel from default `edge` if needed.

name: Build and pubish snap package

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

jobs:
build-and-publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- id: build
uses: snapcore/action-build@v1
#with:
# path: path-to-snapcraft-project
- id: publish
if: github.ref == format('refs/heads/{0}', fromJSON('"main"'))
uses: snapcore/action-publish@v1
env:
SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.STORE_LOGIN }}
with:
snap: ${{ steps.build.outputs.snap }}
release: stable

0 comments on commit c49f437

Please sign in to comment.