Add doc for 'clone' and 'init'.
[stgit] / Documentation / stg.txt
CommitLineData
b24fee3e 1stg(1)
4ec67741
YD
2======
3Yann Dirson <ydirson@altern.org>
4v0.12.1, February 2007
5
6NAME
7----
8stg - manage stacks of patches using the GIT content tracker
9
10SYNOPSIS
11--------
12[verse]
13'stg' [--version] [--help] <command> [OPTIONS] [ARGS]
14
15DESCRIPTION
16-----------
17
18StGIT (Stacked GIT) is an application providing similar functionality
19to Quilt (i.e. pushing/popping patches to/from a stack), on top of
20GIT. These operations are performed using GIT commands and the patches
21are stored as GIT commit objects, allowing easy merging of the StGIT
22patches into other repositories using standard GIT functionality.
23
bfbfd4e5
YD
24An StGIT stack is a GIT branch with additional information to help
25making changes to individual patches you already committed, rather
26than making changes by adding new commits. It is thus a
27non-forwarding, or rewinding branch: the old head of the branch is
28often not reachable as one of the new head's ancestors.
29
4ec67741
YD
30Typical uses of StGIT include:
31
32Tracking branch::
bfbfd4e5
YD
33 Tracking changes from a remote branch, while maintaining local
34 modifications against that branch, possibly with the intent of
35 sending some patches upstream. StGIT assists in preparing and
36 cleaning up patches until they are acceptable upstream, as
37 well as maintaining local patches not meant to be sent
38 upstream.
39+
40In such a setup, typically all commits on your branch are StGIT
41patches; the stack base is the branch point where your changes "fork"
42off their parent branch.
4ec67741
YD
43
44Development branch::
45 Preparing and testing your commits before publishing them,
46 separating your features from unrelated bugfixes collected
47 while developping.
bfbfd4e5
YD
48+
49In such a setup, not all commits on your branch need to be StGIT
50patches; there may be regular GIT commits below your stack base.
4ec67741
YD
51
52OPTIONS
53-------
54
55--version::
56 Prints the StGIT suite version that the 'stg' program came
57 from, as well as version of other components used, such as GIT
58 and Python.
59
60--help::
61 Prints the synopsis and a list of all commands. If a git
62 command is given this option will display the specific help
63 for that command.
64
65STGIT COMMANDS
66--------------
67
68We divide StGIT commands in thematic groups, according to the primary
69type of object they create or change.
70
71ifdef::backend-docbook[]
72Here is a short description of each command. A more detailed
73description is available in individual command manpages. Those
74manpages are named 'stg-<command>(1)'.
75endif::backend-docbook[]
76
77Generic commands
78~~~~~~~~~~~~~~~~
79
80User-support commands not touching the repository.
81
c2b87fa2 82stg help::
4ec67741 83 stgdesc:help[]
c2b87fa2 84stg version::
4ec67741 85 stgdesc:version[]
c2b87fa2 86stg copyright::
4ec67741
YD
87 stgdesc:copyright[]
88
89Repository commands
90~~~~~~~~~~~~~~~~~~~
91
92stglink:clone[]::
93 stgdesc:clone[]
94stglink:id[]::
95 stgdesc:id[]
96
97Stack commands
98~~~~~~~~~~~~~~
99
100Stack management
101^^^^^^^^^^^^^^^^
102
103stglink:branch[]::
104 stgdesc:branch[]
105stglink:init[]::
106 stgdesc:init[]
107stglink:clean[]::
108 stgdesc:clean[]
109stglink:pull[]::
110 stgdesc:pull[]
111stglink:rebase[]::
112 stgdesc:rebase[]
113
114stglink:commit[]::
115 stgdesc:commit[]
116stglink:uncommit[]::
117 stgdesc:uncommit[]
118stglink:assimilate[]::
119 stgdesc:assimilate[]
120
121Controlling what patches are applied
122^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
123
124stglink:series[]::
125 stgdesc:series[]
126stglink:push[]::
127 stgdesc:push[]
128stglink:pop[]::
129 stgdesc:pop[]
130stglink:goto[]::
131 stgdesc:goto[]
132stglink:float[]::
133 stgdesc:float[]
134stglink:applied[]::
135 stgdesc:applied[]
136stglink:unapplied[]::
137 stgdesc:unapplied[]
138stglink:top[]::
139 stgdesc:top[]
140
141stglink:hide[]::
142 stgdesc:hide[]
143stglink:unhide[]::
144 stgdesc:unhide[]
145
146Miscellaneous stack commands
147^^^^^^^^^^^^^^^^^^^^^^^^^^^^
148
149stglink:patches[]::
150 stgdesc:patches[]
151
152
153Patch commands
154~~~~~~~~~~~~~~
155
156Patch management
157^^^^^^^^^^^^^^^^
158
159stglink:new[]::
160 stgdesc:new[]
161stglink:delete[]::
162 stgdesc:delete[]
163stglink:rename[]::
164 stgdesc:rename[]
165stglink:log[]::
166 stgdesc:log[]
167
168Controlling patch contents
169^^^^^^^^^^^^^^^^^^^^^^^^^^
170
171stglink:files[]::
172 stgdesc:files[]
173stglink:show[]::
174 stgdesc:show[]
175stglink:refresh[]::
176 stgdesc:refresh[]
177stglink:fold[]::
178 stgdesc:fold[]
179stglink:pick[]::
180 stgdesc:pick[]
181stglink:sync[]::
182 stgdesc:sync[]
183
184Interaction with the rest of the world
185^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
186
187stglink:export[]::
188 stgdesc:export[]
189stglink:import[]::
190 stgdesc:import[]
191stglink:mail[]::
192 stgdesc:mail[]
193
194
195Working-copy commands
196~~~~~~~~~~~~~~~~~~~~~
197
198stglink:add[]::
199 stgdesc:add[]
200stglink:rm[]::
201 stgdesc:rm[]
d5ae2173
YD
202stglink:cp[]::
203 stgdesc:cp[]
4ec67741
YD
204stglink:status[]::
205 stgdesc:status[]
206stglink:diff[]::
207 stgdesc:diff[]
208stglink:resolved[]::
209 stgdesc:resolved[]
210
211CONFIGURATION MECHANISM
212-----------------------
213
214Starting with 0.12, StGIT uses the same configuration mechanism as
215GIT. See gitlink:git[7] for more details.
216
217TEMPLATES
218---------
219
220A number of StGIT commands make use of template files to provide
221useful default texts to be edited by the user. These '<name>.tmpl'
222template files are searched in the following directories:
223
224 $GITDIR/
225 $HOME/.stgit/templates/
226 /usr/share/stgit/templates/