Applypatch
applyPatchApply a unified diff to one existing local file with GNU patch, using a configurable strip level and restricted options.
Instructions
Apply diff from stdin to one explicit local file using GNU patch.
pnum is GNU patch's -pNUM value. The target must be an existing
regular file beneath the configured current directory. Additional options
are restricted to a small allowlist that cannot select input/output files,
another target, a directory, or a different strip value.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| args | No | ||
| diff | Yes | ||
| file | Yes | ||
| pnum | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |