Skip to content

Commit

Permalink
Add workflow to test snap packaging
Browse files Browse the repository at this point in the history
- Update runner versions
  • Loading branch information
hsbasu committed Feb 15, 2024
1 parent 33a8d9d commit 87ce3d2
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@master
with:
submodules: recursive

Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@master

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
Expand All @@ -52,7 +52,7 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1
uses: github/codeql-action/autobuild@v2

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl
Expand All @@ -66,4 +66,4 @@ jobs:
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
uses: github/codeql-action/analyze@v2
2 changes: 1 addition & 1 deletion .github/workflows/publish-deb.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@master
with:
fetch-depth: 0

Expand Down
29 changes: 29 additions & 0 deletions .github/workflows/snapcraft.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Test Snap packaging

on:
push:
branches: [ "**" ]
workflow_dispatch:

permissions:
id-token: write
contents: read
jobs:
gnome-snap:
name: "Snap"
runs-on: ubuntu-latest
steps:
- name: Checkout Git repository
uses: actions/checkout@v4
- name: Use source from current branch
run: |
sed -i 's/source:.*/source: ./g' snap/snapcraft.yaml
- name: Test snap building
uses: snapcore/action-build@v1
id: snapcraft-build
with:
snapcraft-args: "--verbose"
- uses: actions/upload-artifact@v4
with:
name: simple-pwgen-snap
path: ${{ steps.snapcraft-build.outputs.snap }}

0 comments on commit 87ce3d2

Please sign in to comment.