diff --git a/.github/ISSUE_TEMPLATE/3-app.yml b/.github/ISSUE_TEMPLATE/3-app.yml index b426876..78afa88 100644 --- a/.github/ISSUE_TEMPLATE/3-app.yml +++ b/.github/ISSUE_TEMPLATE/3-app.yml @@ -4,13 +4,9 @@ title: 'App: ' labels: - app body: -- type: input - id: app +- type: markdown attributes: - label: Which app? - placeholder: Obsidian - validations: - required: true + value: Just add the app's name to the title. The rest is optional. - type: dropdown id: install attributes: @@ -21,7 +17,3 @@ body: - Flatpak - Snap - AppImage -- type: textarea - id: more - attributes: - label: Anything else? diff --git a/.github/workflows/issues.yml b/.github/workflows/issues.yml index 52e3696..8a2619d 100644 --- a/.github/workflows/issues.yml +++ b/.github/workflows/issues.yml @@ -2,34 +2,17 @@ name: issues on: issues: - types: [opened, labeled] + types: [labeled] permissions: issues: write jobs: - # Users can leave the title alone, it gets the app's name. - title: - name: name app issues after the app - if: github.event.action == 'opened' && contains(github.event.issue.labels.*.name, 'app') - runs-on: ubuntu-latest - steps: - - env: - GH_TOKEN: ${{ github.token }} - BODY: ${{ github.event.issue.body }} - NUMBER: ${{ github.event.issue.number }} - run: | - app=$(printf '%s\n' "$BODY" | tr -d '\r' \ - | awk '/^### /{f = ($0 == "### Which app?"); next} f && NF {print; exit}') - if [ -n "$app" ] && [ "$app" != "_No response_" ]; then - gh issue edit "$NUMBER" --repo "$GITHUB_REPOSITORY" --title "App: ${app:0:80}" - fi - # The "fixed" and "not chromium" labels answer and close the issue. close: name: close on label if: >- - github.event.action == 'labeled' && github.event.issue.state == 'open' + github.event.issue.state == 'open' && (github.event.label.name == 'fixed' || github.event.label.name == 'not chromium') runs-on: ubuntu-latest steps: