table of contents
STG-NEW(1) | StGit Manual | STG-NEW(1) |
NAME¶
stg-new - Create a new patch at top of the stack
SYNOPSIS¶
stg new [OPTIONS] [patchname] [-- <path>...] stg new [OPTIONS] [--name <patchname>] [-- <path>...]
DESCRIPTION¶
Create a new, empty patch on the current stack. The new patch is created on top of the currently applied patches, and is made the new top of the stack. Uncommitted changes in the work tree are not included in the patch — that is handled by stg-refresh.
The given patch name must be unique in the stack. If no name is given, one is generated from the first line of the patch’s commit message.
Patch names follow the rules for Git references with the additional constraint that patch names may not contain the / character. See git-check-ref-format(1) for details.
Patch names may start with a leading -. When specifying such a patch name on the command line, the leading - may be escaped with a single backslash as in \-patch-name to disambiguate the patch name from command line options.
An editor will be launched to edit the commit message to be used for the patch, unless the --message flag already specified one. The patchdescr.tmpl template file (if available) is used to pre-fill the editor.
OPTIONS¶
-n <name>, --name=<name>
-r, --refresh
-i, --index
-F, --force
By default, if there are staged changes in the index along with unstaged changes in the work tree, the command will abort. This option forces the command to proceed using both the staged and unstaged changes.
--submodules
--no-submodules
-e, --edit
-d, --diff
-m <message>, --message=<message>
-f <path>, --file=<path>
--no-verify
-s[=<value>], --signoff[=<value>]
The value is optional and defaults to the committer name and email. This option may be provided multiple times.
--ack[=<value>]
The value is optional and defaults to the committer’s name and email. This option may be provided multiple times.
--review[=<value>]
The value is optional and defaults to the committer’s name and email. This option may be provided multiple times.
--author=<name-and-email>
--authname=<name>
--authemail=<email>
--authdate=<date>
Use "now" to use the current time and date.
--committer-date-is-author-date
--save-template=<file>
When driving StGit from another program, it may be useful to first call a command with --save-template, then let the user edit the message, and then call the same command with --file.
STGIT¶
Part of the StGit suite - see stg(1)
09/20/2024 | StGit 2.4.12 |