GitXplorerGitXplorer
p

suggest-changes

public
12 stars
6 forks
5 issues

Commits

List of commits on branch main.
Verified
434fedd546c7ae6523d7b50aa4797a228a0f2d55

chore(main): release 2.0.0 (#52)

rrelease-please[bot] committed 3 months ago
Verified
12a43fe109109fb30da138552a09110aaa05fbc2

feat!: Add pull request review event input (#51)

pparkerbxyz committed 3 months ago
Verified
a2ec1653b0c4cc8287d682f0066dba4a173cc7f3

chore(main): release 1.0.8 (#47)

rrelease-please[bot] committed 3 months ago
Verified
994b05c86015100c4eda318cb65edfad5dfc381c

fix: generate diffs with one line of context (#49)

pparkerbxyz committed 3 months ago
Verified
c35484939d5468a93d4c281bff5fa1e67a8339ec

fix(deps): bump parse-git-diff from 0.0.15 to 0.0.16 (#40)

ddependabot[bot] committed 3 months ago
Verified
0ab04c7e5f92083ced5e2fa7021fe8858ba85f44

chore(main): release 1.0.7 (#46)

rrelease-please[bot] committed 3 months ago

README

The README file for this repository.

Suggest changes

This GitHub Action takes changes from the working directory (using git diff) and applies them as suggested changes in a pull request review. This can be useful after running a linter or formatter that automatically makes fixes for you.

  • Gives contributors an opportunity to review and accept automated changes
  • Enables semi-automated changes to pull requests without the needing to use a personal access token (PAT) or GitHub App installation token to trigger workflow runs

[!NOTE] This GitHub Action only works on pull_request workflow events.

Usage

You can use this action in an existing workflow and have it run after a linter or formatter step. For example, if you have a workflow that runs markdownlint on all Markdown files in a pull request, you can use this action to suggest changes to the pull request after markdownlint has run.

name: 'markdownlint'

on:
  pull_request:
    paths: ['**/*.md']

permissions:
  contents: read
  pull-requests: write

jobs:
  lint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: DavidAnson/markdownlint-cli2-action@v15
        with:
          fix: true
          globs: '**/*.md'
      - uses: parkerbxyz/suggest-changes@v1
        with:
          comment: 'Please commit the suggested changes from markdownlint.'
          event: 'REQUEST_CHANGES'

[!NOTE] Suggested changes are limited to 3000 files per pull request

Here is what an automated pull request review with suggested changes would look like using the workflow configuration above:

A screenshot showing an automated pull request review with suggested changes