{
    "content": [
        {
            "type": "text",
            "text": "# patch (info)\n\n## Sections\n\n- **File: diffutils.info,  Node: Invoking patch,  Next: Invoking sdiff,  Prev: Invoking diff3,  Up: Top**\n- **15 Invoking 'patch'**\n- **File: diffutils.info,  Node: patch Options,  Up: Invoking patch** (1 subsections)\n\nUse structuredContent.sections for detailed options, examples, and full documentation.\n"
        }
    ],
    "structuredContent": {
        "command": "patch",
        "section": "",
        "mode": "info",
        "summary": null,
        "synopsis": null,
        "tldr_summary": null,
        "tldr_examples": [],
        "tldr_source": null,
        "flags": [],
        "examples": [],
        "see_also": [],
        "section_outline": [
            {
                "name": "File: diffutils.info,  Node: Invoking patch,  Next: Invoking sdiff,  Prev: Invoking diff3,  Up: Top",
                "lines": 1,
                "subsections": []
            },
            {
                "name": "15 Invoking 'patch'",
                "lines": 29,
                "subsections": []
            },
            {
                "name": "File: diffutils.info,  Node: patch Options,  Up: Invoking patch",
                "lines": 1,
                "subsections": [
                    {
                        "name": "15.1 Options to 'patch'",
                        "lines": 176
                    }
                ]
            }
        ],
        "sections": {
            "File: diffutils.info,  Node: Invoking patch,  Next: Invoking sdiff,  Prev: Invoking diff3,  Up: Top": {
                "content": "",
                "subsections": []
            },
            "15 Invoking 'patch'": {
                "content": "Normally 'patch' is invoked like this:\n\npatch <PATCHFILE\n\nThe full format for invoking 'patch' is:\n\npatch OPTIONS... [ORIGFILE [PATCHFILE]]\n\nYou can also specify where to read the patch from with the '-i\nPATCHFILE' or '--input=PATCHFILE' option.  If you do not specify\nPATCHFILE, or if PATCHFILE is '-', 'patch' reads the patch (that is, the\n'diff' output) from the standard input.\n\nIf you do not specify an input file on the command line, 'patch'\ntries to intuit from the \"leading text\" (any text in the patch that\ncomes before the 'diff' output) which file to edit.  *Note Multiple\nPatches::.\n\nBy default, 'patch' replaces the original input file with the patched\nversion, possibly after renaming the original file into a backup file\n(*note Backup Names::, for a description of how 'patch' names backup\nfiles).  You can also specify where to put the output with the '-o FILE'\nor '--output=FILE' option; however, do not use this option if FILE is\none of the input files.\n\n* Menu:\n\n* patch Options::     Summary table of options to 'patch'.\n",
                "subsections": []
            },
            "File: diffutils.info,  Node: patch Options,  Up: Invoking patch": {
                "content": "",
                "subsections": [
                    {
                        "name": "15.1 Options to 'patch'",
                        "content": "Here is a summary of all of the options that GNU 'patch' accepts.  *Note\npatch and Tradition::, for which of these options are safe to use in\nolder versions of 'patch'.\n\nMultiple single-letter options that do not take an argument can be\ncombined into a single command line argument with only one dash.\n\n'-b'\n'--backup'\nBack up the original contents of each file, even if backups would\nnormally not be made.  *Note Backups::.\n\n'-B PREFIX'\n'--prefix=PREFIX'\nPrepend PREFIX to backup file names.  *Note Backup Names::.\n\n'--backup-if-mismatch'\nBack up the original contents of each file if the patch does not\nexactly match the file.  This is the default behavior when not\nconforming to POSIX. *Note Backups::.\n\n'--binary'\nRead and write all files in binary mode, except for standard output\nand '/dev/tty'.  This option has no effect on POSIX-conforming\nsystems like GNU/Linux.  On systems where this option makes a\ndifference, the patch should be generated by 'diff -a --binary'.\n*Note Binary::.\n\n'-c'\n'--context'\nInterpret the patch file as a context diff.  *Note patch Input::.\n\n'-d DIRECTORY'\n'--directory=DIRECTORY'\nMake directory DIRECTORY the current directory for interpreting\nboth file names in the patch file, and file names given as\narguments to other options.  *Note patch Directories::.\n\n'-D NAME'\n'--ifdef=NAME'\nMake merged if-then-else output using NAME.  *Note If-then-else::.\n\n'--dry-run'\nPrint the results of applying the patches without actually changing\nany files.  *Note Dry Runs::.\n\n'-e'\n'--ed'\nInterpret the patch file as an 'ed' script.  *Note patch Input::.\n\n'-E'\n'--remove-empty-files'\nRemove output files that are empty after the patches have been\napplied.  *Note Creating and Removing::.\n\n'-f'\n'--force'\nAssume that the user knows exactly what he or she is doing, and do\nnot ask any questions.  *Note patch Messages::.\n\n'-F LINES'\n'--fuzz=LINES'\nSet the maximum fuzz factor to LINES.  *Note Inexact::.\n\n'-g NUM'\n'--get=NUM'\nIf NUM is positive, get input files from a revision control system\nas necessary; if zero, do not get the files; if negative, ask the\nuser whether to get the files.  *Note Revision Control::.\n\n'--help'\nOutput a summary of usage and then exit.\n\n'-i PATCHFILE'\n'--input=PATCHFILE'\nRead the patch from PATCHFILE rather than from standard input.\n*Note patch Options::.\n\n'-l'\n'--ignore-white-space'\nLet any sequence of blanks (spaces or tabs) in the patch file match\nany sequence of blanks in the input file.  *Note Changed White\nSpace::.\n\n'-n'\n'--normal'\nInterpret the patch file as a normal diff.  *Note patch Input::.\n\n'-N'\n'--forward'\nIgnore patches that 'patch' thinks are reversed or already applied.\nSee also '-R'.  *Note Reversed Patches::.\n\n'--no-backup-if-mismatch'\nDo not back up the original contents of files.  This is the default\nbehavior when conforming to POSIX. *Note Backups::.\n\n'-o FILE'\n'--output=FILE'\nUse FILE as the output file name.  *Note patch Options::.\n\n'-pNUMBER'\n'--strip=NUMBER'\nSet the file name strip count to NUMBER.  *Note patch\nDirectories::.\n\n'--posix'\nConform to POSIX, as if the 'POSIXLYCORRECT' environment variable\nhad been set.  *Note patch and POSIX::.\n\n'--quoting-style=WORD'\nUse style WORD to quote names in diagnostics, as if the\n'QUOTINGSTYLE' environment variable had been set to WORD.  *Note\npatch Quoting Style::.\n\n'-r REJECT-FILE'\n'--reject-file=REJECT-FILE'\nUse REJECT-FILE as the reject file name.  *Note Reject Names::.\n\n'-R'\n'--reverse'\nAssume that this patch was created with the old and new files\nswapped.  *Note Reversed Patches::.\n\n'-s'\n'--quiet'\n'--silent'\nWork silently unless an error occurs.  *Note patch Messages::.\n\n'-t'\n'--batch'\nDo not ask any questions.  *Note patch Messages::.\n\n'-T'\n'--set-time'\nSet the modification and access times of patched files from\ntimestamps given in context diff headers, assuming that the context\ndiff headers use local time.  *Note Patching Timestamps::.\n\n'-u'\n'--unified'\nInterpret the patch file as a unified diff.  *Note patch Input::.\n\n'-v'\n'--version'\nOutput version information and then exit.\n\n'-V BACKUP-STYLE'\n'--version=control=BACKUP-STYLE'\nSelect the naming convention for backup file names.  *Note Backup\nNames::.\n\n'--verbose'\nPrint more diagnostics than usual.  *Note patch Messages::.\n\n'-x NUMBER'\n'--debug=NUMBER'\nSet internal debugging flags.  Of interest only to 'patch'\npatchers.\n\n'-Y PREFIX'\n'--basename-prefix=PREFIX'\nPrepend PREFIX to base names of backup files.  *Note Backup\nNames::.\n\n'-z SUFFIX'\n'--suffix=SUFFIX'\nUse SUFFIX as the backup extension instead of '.orig' or '~'.\n*Note Backup Names::.\n\n'-Z'\n'--set-utc'\nSet the modification and access times of patched files from\ntimestamps given in context diff headers, assuming that the context\ndiff headers use UTC. *Note Patching Timestamps::.\n"
                    }
                ]
            }
        }
    }
}