Skip to content

Commit

Permalink
fix: create ticket GH action (#467)
Browse files Browse the repository at this point in the history
Fixes the leftover issues with the version bump ticket creation action.

---------

Co-authored-by: gera <gerared45@gmail.com>
  • Loading branch information
2 people authored and Ad96el committed Mar 20, 2023
1 parent 531b834 commit 267de5f
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 14 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/add-ticket-to-weekly.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Add Polkadot version upgrade ticket to weekly board

on:
issues:
types:
- opened

jobs:
add-to-weekly-board:
runs-on: ubuntu-latest
steps:
- name: Add new issue to weekly board
uses: actions/add-to-project@0.4.0
with:
project-url: https://github.com/orgs/KILTprotocol/projects/24
github-token: ${{ secrets.REPO_ACCESS_TOKEN }}
labeled: kiltbot
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: create-polkadot-release-ticket
name: Create Polkadot version upgrade ticket

on:
workflow_dispatch:
Expand All @@ -11,7 +11,7 @@ on:
description: Target version of the Polkadot/Cumulus dependency
required: true
type: string
asignee:
assignee:
description: Person assigned for this upgrade
required: false
default: weichweich
Expand All @@ -25,16 +25,20 @@ on:
jobs:
create-ticket:
runs-on: ubuntu-latest
container:
image: rust:1.67.0
steps:
- name: Install cargo
run: curl https://sh.rustup.rs -sSf | sh
- name: Install subalfred
env:
- SUBALFRED_VERSION: 0.9.1
SUBALFRED_VERSION: 0.9.1
run: cargo install --version $SUBALFRED_VERSION --git https://github.com/hack-ink/subalfred.git subalfred
- name: Run subalfred for Substrate
env:
GITHUB_TOKEN: ${{ secrets.REPO_ACCESS_TOKEN }}
run: subalfred track-updates paritytech/substrate --from polkadot-v${{ inputs.current-version }} --to polkadot-v${{ inputs.target-version }} > substrate-out.md
- name: Run subalfred for Cumulus
env:
GITHUB_TOKEN: ${{ secrets.REPO_ACCESS_TOKEN }}
run: subalfred track-updates paritytech/cumulus --from polkadot-v${{ inputs.current-version }} --to polkadot-v${{ inputs.target-version }} > cumulus-out.md
- name: Merge outputs into single file
run: |
Expand All @@ -45,16 +49,13 @@ jobs:
- name: Create issue from commands output
id: new-issue
uses: peter-evans/create-issue-from-file@v3
env:
GITHUB_TOKEN: ${{ secrets.REPO_ACCESS_TOKEN }}
with:
title: "chore: update Polkadot dependencies from ${{ inputs.current-version }} to ${{ inputs.target-version }}"
repository: KILTProtocol/ticket
title: "[AUTOMATIC] Update Polkadot dependencies from ${{ inputs.current-version }} to ${{ inputs.target-version }}"
repository: KILTProtocol/kilt-node
token: ${{ secrets.REPO_ACCESS_TOKEN }}
content-filepath: out.md
- name: Put issue into weekly board
uses: peter-evans/create-or-update-project-card@v2
with:
# Weekly board
project-number: 24
column-name: "📥 Inbox"
issue-number: ${{ steps.new-issue.outputs.issue-number }}
labels: kiltbot,⛓ KILT node
assignees: ${{ github.event.inputs.assignee }}

0 comments on commit 267de5f

Please sign in to comment.