-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from soumyaDghosh/2204
ci: add workflow automation to webkitgtk-sdk
- Loading branch information
Showing
9 changed files
with
302 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: Promote to stable | ||
|
||
on: | ||
issue_comment: | ||
types: | ||
- created | ||
|
||
permissions: | ||
issues: write | ||
|
||
jobs: | ||
promote-content: | ||
name: ⬆️ Promote Content to stable | ||
environment: "2204 Branch" | ||
runs-on: ubuntu-latest | ||
if: | | ||
( !github.event.issue.pull_request ) | ||
&& contains(github.event.comment.body, '/promote ') | ||
&& contains(github.event.issue.body, '`webkitgtk-6-gnome-2204 `') | ||
&& contains(github.event.*.labels.*.name, 'testing') | ||
steps: | ||
- name: ⬆️ Promote to stable | ||
uses: snapcrafters/ci/promote-to-stable@main | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
store-token: ${{ secrets.SNAP_STORE_STABLE }} | ||
snapcraft-project-root: "webkitgtk-6-gnome-2204" | ||
|
||
promote-sdk: | ||
name: ⬆️ Promote SDK to stable | ||
environment: "2204 Branch" | ||
runs-on: ubuntu-latest | ||
if: | | ||
( !github.event.issue.pull_request ) | ||
&& contains(github.event.comment.body, '/promote ') | ||
&& contains(github.event.issue.body, '`webkitgtk-6-gnome-2204-sdk`') | ||
&& contains(github.event.*.labels.*.name, 'testing') | ||
steps: | ||
- name: ⬆️ Promote to stable | ||
uses: snapcrafters/ci/promote-to-stable@main | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
store-token: ${{ secrets.SNAP_STORE_STABLE }} | ||
snapcraft-project-root: "webkitgtk-6-gnome-2204-sdk" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
name: Pull Request for webkitgtk-6-gnome-2204 | ||
|
||
on: | ||
pull_request: | ||
branches: ["**"] | ||
paths: | ||
- "webkitgtk-6-gnome-2204/**" | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
build: | ||
name: 🧪 Build snap on amd64 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: 🧪 Build snap on amd64 | ||
uses: snapcrafters/ci/test-snap-build@main | ||
with: | ||
snapcraft-project-root: webkitgtk-6-gnome-2204 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
name: Pull Request for webkitgtk-6-gnome-2204-sdk | ||
|
||
on: | ||
pull_request: | ||
branches: ["**"] | ||
paths: | ||
- "webkitgtk-6-gnome-2204-sdk/**" | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
build: | ||
name: 🧪 Build snap on amd64 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: 🧪 Build snap on amd64 | ||
uses: snapcrafters/ci/test-snap-build@main | ||
with: | ||
snapcraft-project-root: webkitgtk-6-gnome-2204-sdk |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
name: Release webkitgtk-6-gnome-2204 to candidate | ||
|
||
on: | ||
workflow_run: | ||
workflows: ["Release webkitgtk-6-gnome-2204-sdk to candidate"] | ||
types: [completed] | ||
paths: | ||
- "webkitgtk-6-gnome-2204/**" | ||
workflow_dispatch: | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
permissions: | ||
contents: read | ||
issues: write | ||
|
||
jobs: | ||
get-architectures: | ||
if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' }} | ||
name: 🖥 Get snap architectures | ||
runs-on: ubuntu-latest | ||
outputs: | ||
architectures: ${{ steps.get-architectures.outputs.architectures }} | ||
architectures-list: ${{ steps.get-architectures.outputs.architectures-list }} | ||
steps: | ||
- name: 🖥 Get snap architectures | ||
id: get-architectures | ||
uses: snapcrafters/ci/get-architectures@main | ||
with: | ||
snapcraft-project-root: "webkitgtk-6-gnome-2204" | ||
|
||
release-content: | ||
name: 🚢 Release to latest/candidate | ||
needs: get-architectures | ||
runs-on: ubuntu-latest | ||
environment: "2204 Branch" | ||
strategy: | ||
matrix: | ||
architecture: ${{ fromJSON(needs.get-architectures.outputs.architectures-list) }} | ||
steps: | ||
- name: 🚢 Release to latest/candidate | ||
id: build-amd64 | ||
uses: snapcrafters/ci/release-to-candidate@main | ||
with: | ||
architecture: ${{ matrix.architecture }} | ||
launchpad-token: ${{ secrets.LP_BUILD_SECRET }} | ||
multi-snap: true | ||
snapcraft-project-root: "webkitgtk-6-gnome-2204" | ||
store-token: ${{ secrets.SNAP_STORE_CANDIDATE }} | ||
repo-token: ${{ secrets.SNAPCRAFTERS_BOT_COMMIT }} | ||
|
||
call-for-testing: | ||
if: ${{ github.event_name != 'workflow_dispatch' }} | ||
name: 📣 Create call for testing | ||
needs: [release-content, get-architectures] | ||
environment: "2204 Branch" | ||
runs-on: ubuntu-latest | ||
outputs: | ||
issue-number: ${{ steps.issue.outputs.issue-number }} | ||
steps: | ||
- name: 📣 Create call for testing | ||
id: issue | ||
uses: snapcrafters/ci/call-for-testing@main | ||
with: | ||
snapcraft-project-root: "webkitgtk-6-gnome-2204" | ||
architectures: ${{ needs.get-architectures.outputs.architectures }} | ||
github-token: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
name: Release webkitgtk-6-gnome-2204-sdk to candidate | ||
|
||
on: | ||
# Run the workflow each time new commits are pushed to the candidate branch. | ||
push: | ||
branches: ["2204"] | ||
paths: | ||
- "webkitgtk-6-gnome-2204-sdk/**" | ||
workflow_dispatch: | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
permissions: | ||
contents: read | ||
issues: write | ||
|
||
jobs: | ||
get-architectures: | ||
name: 🖥 Get snap architectures | ||
runs-on: ubuntu-latest | ||
outputs: | ||
architectures: ${{ steps.get-architectures.outputs.architectures }} | ||
architectures-list: ${{ steps.get-architectures.outputs.architectures-list }} | ||
steps: | ||
- name: 🖥 Get snap architectures | ||
id: get-architectures | ||
uses: snapcrafters/ci/get-architectures@main | ||
with: | ||
snapcraft-project-root: "webkitgtk-6-gnome-2204-sdk" | ||
|
||
release-sdk: | ||
name: 🚢 Release to latest/candidate | ||
needs: get-architectures | ||
runs-on: ubuntu-latest | ||
environment: "2204 Branch" | ||
strategy: | ||
matrix: | ||
architecture: ${{ fromJSON(needs.get-architectures.outputs.architectures-list) }} | ||
steps: | ||
- name: 🚢 Release to latest/candidate | ||
uses: snapcrafters/ci/release-to-candidate@main | ||
with: | ||
architecture: ${{ matrix.architecture }} | ||
launchpad-token: ${{ secrets.LP_BUILD_SECRET }} | ||
multi-snap: true | ||
snapcraft-project-root: "webkitgtk-6-gnome-2204-sdk" | ||
store-token: ${{ secrets.SNAP_STORE_CANDIDATE }} | ||
repo-token: ${{ secrets.SNAPCRAFTERS_BOT_COMMIT }} | ||
|
||
call-for-testing: | ||
name: 📣 Create call for testing | ||
needs: [release-sdk, get-architectures] | ||
environment: "2204 Branch" | ||
runs-on: ubuntu-latest | ||
outputs: | ||
issue-number: ${{ steps.issue.outputs.issue-number }} | ||
steps: | ||
- name: 📣 Create call for testing | ||
id: issue | ||
uses: snapcrafters/ci/call-for-testing@main | ||
with: | ||
snapcraft-project-root: "webkitgtk-6-gnome-2204-sdk" | ||
architectures: ${{ needs.get-architectures.outputs.architectures }} | ||
github-token: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
name: Update SDK Snap | ||
|
||
on: | ||
# Runs at 10:00 UTC every day | ||
schedule: | ||
- cron: "0 10 * * *" | ||
# Allows you to run this workflow manually from the Actions tab | ||
workflow_dispatch: | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
sync-sdk: | ||
name: Sync version of the SDK snap with upstream | ||
environment: "2204 Branch" | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Sync version with upstream | ||
uses: snapcrafters/ci/sync-version@main | ||
id: sync-sdk-version | ||
with: | ||
token: ${{ secrets.SNAPCRAFTERS_BOT_COMMIT }} | ||
branch: "2204" | ||
snapcraft-project-root: "webkitgtk-6-gnome-2204-sdk" | ||
update-script: | | ||
WEBKITGTK_VERSION=$(git ls-remote --tags --sort='v:refname' https://github.com/WebKit/WebKit.git '*gtk*' | tail --lines=1 | cut --delimiter='/' --fields=3 | rev | cut -c 4- | rev) | ||
yq -i ".parts.webkitgtk-6-gnome-2204-sdk.source-tag = \"$WEBKITGTK_VERSION\"" webkitgtk-6-gnome-2204-sdk/snapcraft.yaml | ||
webkitgtk_version=$(echo $WEBKITGTK_VERSION | cut -c 11-) | ||
yq -i ".version=\"$webkitgtk_version\"" webkitgtk-6-gnome-2204-sdk/snapcraft.yaml | ||
sync-content-version: | ||
needs: sync-sdk | ||
name: Sync version of the content snap with upstream | ||
environment: "2204 Branch" | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Sync version with upstream | ||
uses: snapcrafters/ci/sync-version@main | ||
with: | ||
token: ${{ secrets.SNAPCRAFTERS_BOT_COMMIT }} | ||
branch: "2204" | ||
snapcraft-project-root: "webkitgtk-6-gnome-2204" | ||
update-script: | | ||
WEBKITGTK_VERSION=$(git ls-remote --tags --sort='v:refname' https://github.com/WebKit/WebKit.git '*gtk*' | tail --lines=1 | cut --delimiter='/' --fields=3 | rev | cut -c 4- | rev) | ||
webkitgtk_version=$(echo $WEBKITGTK_VERSION | cut -c 11-) | ||
yq -i ".version=\"$webkitgtk_version\"" webkitgtk-6-gnome-2204/snapcraft.yaml |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
name: webkitgtk-6-gnome-2204 | ||
base: core22 | ||
version: "2.44.0" | ||
summary: Web content engine for GTK | ||
description: | | ||
Content snap for Webkitgtk-6.0+ | ||
grade: stable | ||
confinement: strict | ||
|
||
slots: | ||
webkitgtk-6-gnome-2204: | ||
interface: content | ||
read: | ||
- / | ||
|
||
parts: | ||
webkitgtk: | ||
plugin: nil | ||
stage-snaps: [webkitgtk-6-gnome-2204-sdk/latest/candidate] | ||
prime: | ||
- -usr/include | ||
- -usr/lib/*/pkgconfig | ||
- -meta* | ||
- -snap* |