1STG-BRANCH(1)                    StGit Manual                    STG-BRANCH(1)
2
3
4

NAME

6       stg-branch - Branch operations: switch, list, create, rename, delete,
7       ...
8

SYNOPSIS

10       stg branch
11       stg branch [--merge] [--] <branch>
12       stg branch --list
13       stg branch --create [--] <new-branch> [<committish>]
14       stg branch --clone [--] [<new-branch>]
15       stg branch --rename [--] [<old-name>] <new-name>
16       stg branch --protect [--] [<branch>]
17       stg branch --unprotect [--] [<branch>]
18       stg branch --delete [--force] [--] <branch>
19       stg branch --cleanup [--force] [--] [<branch>]
20       stg branch --description=<description> [--] [<branch>]
21

DESCRIPTION

23       Create, clone, switch between, rename, or delete development branches
24       within a git repository.
25
26       stg branch
27           Display the name of the current branch.
28
29       stg branch <branch>
30           Switch to the given branch.
31

OPTIONS

33       -l, --list
34           List each branch in the current repository, followed by its branch
35           description (if any). The current branch is prefixed with >.
36           Branches that have been initialized for StGit (with stg-init(1))
37           are prefixed with s. Protected branches are prefixed with p.
38
39       -c, --create
40           Create (and switch to) a new branch. The new branch is already
41           initialized as an StGit patch stack, so you do not have to run stg-
42           init(1) manually. If you give a committish argument, the new branch
43           is based there; otherwise, it is based at the current HEAD.
44
45           StGit will try to detect the branch off of which the new branch is
46           forked, as well as the remote repository from which that parent
47           branch is taken (if any), so that running stg-pull(1) will
48           automatically pull new commits from the correct branch. It will
49           warn if it cannot guess the parent branch (e.g. if you do not
50           specify a branch name as committish).
51
52       --clone
53           Clone the current branch, under the name <new-branch> if specified,
54           or using the current branch’s name plus a timestamp.
55
56           The description of the new branch is set to tell it is a clone of
57           the current branch. The parent information of the new branch is
58           copied from the current branch.
59
60       -r, --rename
61           Rename an existing branch.
62
63       -p, --protect
64           Prevent StGit from modifying a branch — either the current one, or
65           one named on the command line.
66
67       -u, --unprotect
68           Allow StGit to modify a branch — either the current one, or one
69           named on the command line. This undoes the effect of an earlier stg
70           branch --protect command.
71
72       --delete
73           Delete the named branch. If there are any patches left in the
74           branch, StGit will refuse to delete it unless you give the --force
75           flag.
76
77           A protected branch cannot be deleted; it must be unprotected first
78           (see --unprotect above).
79
80           If you delete the current branch, you are switched to the "master"
81           branch, if it exists.
82
83       --cleanup
84           Remove the StGit information for the current or given branch. If
85           there are patches left in the branch, StGit refuses the operation
86           unless --force is given.
87
88           A protected branch cannot be cleaned up; it must be unprotected
89           first (see --unprotect above).
90
91           A cleaned up branch can be re-initialised using the stg init
92           command.
93
94       -d DESCRIPTION, --description DESCRIPTION
95           Set the branch description.
96
97       --merge
98           Merge work tree changes into the other branch.
99
100       --force
101           Force a delete when the series is not empty.
102

STGIT

104       Part of the StGit suite - see stg(1)
105
106
107
108StGit 1.4                         01/22/2022                     STG-BRANCH(1)
Impressum