diff --git a/.github/multi-labeler.yml b/.github/multi-labeler.yml new file mode 100644 index 0000000..a8d5e25 --- /dev/null +++ b/.github/multi-labeler.yml @@ -0,0 +1,43 @@ +version: v1 + +# This file adds labels based on the scopes in +# keymanapp/keyman:resources/scopes/commit-types.json +# Currently it must be manually kept up to date. Not all labels are added, only +# common ones. The others are commented out. + + +labels: + # + # conventional commit / semantic PR styles + # + + - label: 'auto' + matcher: + title: '^auto(\(|:)' + - label: 'change' + matcher: + title: '^change(\(|:)' + - label: 'chore' + matcher: + title: '^chore(\(|:)' + - label: 'docs' + matcher: + title: '^docs(\(|:)' + - label: 'feat' + matcher: + title: '^feat(\(|:)' + - label: 'fix' + matcher: + title: '^fix(\(|:)' + - label: 'maint' + matcher: + title: '^maint(\(|:)' + - label: 'refactor' + matcher: + title: '^refactor(\(|:)' + - label: 'style' + matcher: + title: '^style(\(|:)' + - label: 'test' + matcher: + title: '^test(\(|:)' diff --git a/.github/workflows/auto-approve-and-merge-keyman-server-pr.yml b/.github/workflows/auto-approve-and-merge-keyman-server-pr.yml new file mode 100644 index 0000000..2f24229 --- /dev/null +++ b/.github/workflows/auto-approve-and-merge-keyman-server-pr.yml @@ -0,0 +1,28 @@ +# +# Automatically approves and queues for merge any pull requests with a branch +# name starting with auto/, that are opened by keyman-server. +# +name: Auto Approve and Merge PRs from keyman-server + +on: pull_request_target + +jobs: + auto-approve: + if: github.actor == 'keyman-server' && startsWith(github.head_ref, 'auto/') + runs-on: ubuntu-latest + env: + GH_TOKEN: ${{ secrets.AUTO_PR_APPROVAL_BY_KEYMAN_STATUS }} + permissions: write-all + steps: + - name: Checkout + uses: actions/checkout@v4.1.5 + with: + sparse-checkout: | + README.md + sparse-checkout-cone-mode: false + - name: Approve pull request + run: | + gh pr review --approve ${{github.head_ref}} + - name: Enable auto-merge + run: | + gh pr merge --merge --auto ${{github.head_ref}} diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml new file mode 100644 index 0000000..f0d4218 --- /dev/null +++ b/.github/workflows/labeler.yml @@ -0,0 +1,15 @@ +name: "Pull Request Labeler" +on: +- pull_request + +jobs: + triage: + if: github.repository == 'keymanapp/keymanweb.com' + runs-on: ubuntu-latest + steps: + - name: Update labels based on PR title + id: labeler + uses: fuxingloh/multi-labeler@f5bd7323b53b0833c1e4ed8d7b797ae995ef75b4 # v2.0.1 + with: + github-token: ${{secrets.GITHUB_TOKEN}} + config-path: .github/multi-labeler.yml diff --git a/build.sh b/build.sh index 0cb15ea..04c255d 100755 --- a/build.sh +++ b/build.sh @@ -2,7 +2,7 @@ ## START STANDARD SITE BUILD SCRIPT INCLUDE readonly THIS_SCRIPT="$(readlink -f "${BASH_SOURCE[0]}")" readonly BOOTSTRAP="$(dirname "$THIS_SCRIPT")/resources/bootstrap.inc.sh" -readonly BOOTSTRAP_VERSION=v1.0.2 +readonly BOOTSTRAP_VERSION=v1.0.6 [ -f "$BOOTSTRAP" ] && source "$BOOTSTRAP" || source <(curl -H "Cache-Control: no-cache" -fs https://raw.githubusercontent.com/keymanapp/shared-sites/$BOOTSTRAP_VERSION/bootstrap.inc.sh) ## END STANDARD SITE BUILD SCRIPT INCLUDE