stg-import(1) — Linux manual page

NAME | SYNOPSIS | DESCRIPTION | OPTIONS | STGIT | COLOPHON

STG-IMPORT(1)                 StGit Manual                 STG-IMPORT(1)

NAME         top

       stg-import - Import a GNU diff file as a new patch

SYNOPSIS         top

       stg import [options] [--] [<file>|<url>]

DESCRIPTION         top

       Create a new patch and apply the given GNU diff file (or the
       standard input). By default, the file name is used as the patch
       name but this can be overridden with the --name option. The patch
       can either be a normal file with the description at the top or it
       can have standard mail format, the Subject, From and Date headers
       being used for generating the patch information. The command can
       also read series and mbox files.

       If a patch does not apply cleanly, the failed diff is written to
       the .stgit-failed.patch file and an empty StGit patch is added to
       the stack.

       The patch description has to be separated from the data with a
       --- line.

OPTIONS         top

       -m, --mail
           Import the patch from a standard e-mail file.

       -M, --mbox
           Import a series of patches from an mbox file.

       -s, --series
           Import a series of patches from a series file or a tar
           archive.

       -u, --url
           Import a patch from a URL.

       -n NAME, --name NAME
           Use NAME as the patch name.

       -p N, --strip N
           Remove N leading slashes from diff paths (default 1).

       -t, --stripname
           Strip numbering and extension from patch name.

       -C N
           Ensure N lines of surrounding context for each change.

       -i, --ignore
           Ignore the applied patches in the series.

       --replace
           Replace the unapplied patches in the series.

       -b BASE, --base BASE
           Use BASE instead of HEAD for file importing.

       --reject
           Leave the rejected hunks in corresponding *.rej files.

       --keep-cr
           Do not remove "\r" from email lines ending with "\r\n".

       --message-id
           Create Message-Id trailer in patch description based on the
           Message-ID email header. This option is applicable when
           importing with --mail or --mbox. This behavior may also be
           enabled via the stgit.import.message-id configuration option.

       -e, --edit
           Invoke an editor for the patch description.

       -d, --showdiff
           Show the patch content in the editor buffer.

       --author "NAME <EMAIL>"
           Set the author details.

       --authname NAME
           Set the author name.

       --authemail EMAIL
           Set the author email.

       --authdate DATE
           Set the author date.

       --sign
           Add a "Signed-off-by:" trailer to the end of the message
           using the committer name and email for the trailer value.

       --sign-by VALUE
           Add a "Signed-off-by:" trailer with a custom VALUE to the end
           of the message.

       --ack
           Add an "Acked-by:" trailer to the end of the message using
           the commiter name and email for the trailer value.

       --ack-by VALUE
           Add an "Acked-by:" trailer with a custom VALUE to the end of
           the message.

       --review
           Add a "Reviewed-by:" trailer to the end of the message using
           the commiter name and email for the trailer value.

       --review-by VALUE
           Add a "Reviewed-by:" trailer with custom VALUE to the end of
           the message.

STGIT         top

       Part of the StGit suite - see stg(1)

COLOPHON         top

       This page is part of the stgit (Stacked Git) project.
       Information about the project can be found at 
       ⟨http://www.procode.org/stgit/⟩.  If you have a bug report for
       this manual page, see ⟨http://www.procode.org/stgit/⟩.  This page
       was obtained from the project's upstream Git repository
       ⟨http://repo.or.cz/stgit.git⟩ on 2022-12-17.  (At that time, the
       date of the most recent commit that was found in the repository
       was 2022-01-07.)  If you discover any rendering problems in this
       HTML version of the page, or you believe there is a better or
       more up-to-date source for the page, or you have corrections or
       improvements to the information in this COLOPHON (which is not
       part of the original manual page), send a mail to
       man-pages@man7.org

StGit 1.4.dev34+g8254ffb       12/17/2022                  STG-IMPORT(1)

Pages that refer to this page: stg(1)