mirror of
https://github.com/streamyfin/streamyfin.git
synced 2026-01-16 16:18:09 +00:00
68 lines
2.3 KiB
YAML
68 lines
2.3 KiB
YAML
name: 🐛 Update Bug Report Template
|
|
|
|
on:
|
|
release:
|
|
types: [published] # Run on every published release on any branch
|
|
|
|
concurrency:
|
|
group: update-issue-form-${{ github.event.release.tag_name || github.run_id }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
update-bug-report:
|
|
permissions:
|
|
contents: write
|
|
pull-requests: write
|
|
issues: write
|
|
runs-on: ubuntu-24.04
|
|
|
|
steps:
|
|
- name: 📥 Checkout repository
|
|
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
|
|
|
- name: "🟢 Setup Node.js"
|
|
uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
|
|
with:
|
|
node-version: '24.x'
|
|
cache: 'npm'
|
|
|
|
- name: 🔍 Extract minor version from app.json
|
|
id: minor
|
|
uses: actions/github-script@main
|
|
with:
|
|
result-encoding: string
|
|
script: |
|
|
const fs = require('fs-extra');
|
|
const semver = require('semver');
|
|
const content = fs.readJsonSync('./app.json');
|
|
const version = content.expo.version;
|
|
const minorVersion = semver.minor(version);
|
|
return minorVersion.toString();
|
|
|
|
- name: 📝 Update bug report version
|
|
uses: ShaMan123/gha-populate-form-version@be012141ca560dbb92156e3fe098c46035f6260d #v2.0.5
|
|
with:
|
|
semver: '^0.${{ steps.minor.outputs.result }}.0'
|
|
dry_run: no-push
|
|
|
|
- name: ⚙️ Update bug report node version dropdown
|
|
uses: ShaMan123/gha-populate-form-version@be012141ca560dbb92156e3fe098c46035f6260d #v2.0.5
|
|
with:
|
|
dropdown: _node_version
|
|
package: node
|
|
semver: '>=24.0.0'
|
|
dry_run: no-push
|
|
|
|
- name: 📬 Commit and create pull request
|
|
uses: peter-evans/create-pull-request@98357b18bf14b5342f975ff684046ec3b2a07725 # v8.0.0
|
|
with:
|
|
add-paths: .github/ISSUE_TEMPLATE/bug_report.yml
|
|
branch: ci-update-bug-report
|
|
base: develop
|
|
delete-branch: true
|
|
labels: ⚙️ ci, 🤖 github-actions
|
|
title: 'chore(): Update bug report template to match release version'
|
|
body: |
|
|
Automated update to `.github/ISSUE_TEMPLATE/bug_report.yml`
|
|
Triggered by workflow run [${{ github.run_id }}](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }})
|