grantbirki/git-diff-action
A GitHub Action for gathering the `git diff` of a pull request in JSON format
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Stale
- License
- None
Inputs
| name | description | required | default |
|---|---|---|---|
| base_branch | The "base" or "target" branch to use for the git diff | yes | HEAD^1 |
| json_diff_file_output | Optionally write the JSON diff output to a file | no | "" |
| raw_diff_file_output | Optionally write the raw diff output to a file | no | "" |
| file_output_only | Only use file related outputs and do not print any diffs to console / loggers | no | false |
| search_path | Optionally limit the scope of the diff operation to a specific sub-path | no | . |
| max_buffer_size | Maximum output buffer size. Defaults to 10M, try increasing if you have issues. This value is technically a string but it gets converted to an integer. | no | 10000000 |
| git_options | Additional git diff options to pass to the git binary as argv tokens | no | --no-color --full-index |
| git_diff_file | Optionally read the diff from a file inside the GitHub workspace instead of running `git diff` | no | false |
Outputs
| name | description |
|---|---|
| json-diff | The `git diff` of the pull request in JSON format |
| raw-diff | The raw `git diff` of the pull request |
| json-diff-path | The path to the JSON diff file |
| raw-diff-path | The path to the raw diff file |