name: PR Bot on: pull_request_target: types: [opened] permissions: contents: read pull-requests: write jobs: pr-bot: name: Automated PR Bot runs-on: ubuntu-latest steps: - name: Label by file path uses: actions/labeler@v5 with: repo-token: ${{ secrets.GITHUB_TOKEN }} - name: Label by size uses: Gascon1/pr-size-labeler@v1.3.0 with: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} xs_label: 'small-change' xs_diff: '9' s_label: 'non-trivial' s_diff: '99999' fail_if_xl: 'false' excluded_files: > /\.lock$/ /\.txt$/ - name: Welcome comment if: ${{ !contains(github.actor, 'bot') }} uses: actions/github-script@v7 with: script: | const pr = context.payload.pull_request; const user = pr.user.login; const body = ` Hello @${user}, Thank you very much for submitting this PR to us! This is what will happen next: 1. CI tests will run against your PR to ensure quality and consistency. 2. Next, human contributors from paperless-ngx review your changes. 3. Please address any issues that come up during the review as soon as you are able to. 4. If accepted, your pull request will be merged into the \`dev\` branch and changes there will be tested further. 5. Eventually, changes from you and other contributors will be merged into \`main\` and a new release will be made. You'll be hearing from us soon, and thank you again for contributing to our project. `; await github.rest.issues.createComment({ issue_number: pr.number, owner: context.repo.owner, repo: context.repo.repo, body, });