Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
api-builtin.txt: update and fix typo
author
Stephan Beyer
<s-beyer@gmx.net>
Sat, 21 Jun 2008 23:54:36 +0000
(
01:54
+0200)
committer
Junio C Hamano
<gitster@pobox.com>
Mon, 23 Jun 2008 01:14:17 +0000
(18:14 -0700)
Mention NEED_WORK_TREE flag and command-list.txt.
Fix "bulit-in" typo and AsciiDoc-formatting of a paragraph.
Signed-off-by: Stephan Beyer <s-beyer@gmx.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/technical/api-builtin.txt
patch
|
blob
|
history
raw
|
patch
|
inline
| side by side (parent:
3b2bbe9
)
diff --git
a/Documentation/technical/api-builtin.txt
b/Documentation/technical/api-builtin.txt
index 52cdb4c5201b7971ba908c35722e4914f408fbec..7ede1e64e5d40ec8f742e900d7273d6f961605e2 100644
(file)
--- a/
Documentation/technical/api-builtin.txt
+++ b/
Documentation/technical/api-builtin.txt
@@
-4,7
+4,7
@@
builtin API
Adding a new built-in
---------------------
Adding a new built-in
---------------------
-There are 4 things to do to add a bu
li
t-in command implementation to
+There are 4 things to do to add a bu
il
t-in command implementation to
git:
. Define the implementation of the built-in command `foo` with
git:
. Define the implementation of the built-in command `foo` with
@@
-18,8
+18,8
@@
git:
defined in `git.c`. The entry should look like:
{ "foo", cmd_foo, <options> },
defined in `git.c`. The entry should look like:
{ "foo", cmd_foo, <options> },
-
-
where options is the bitwise-or of:
++
+where options is the bitwise-or of:
`RUN_SETUP`::
`RUN_SETUP`::
@@
-33,6
+33,12
@@
git:
If the standard output is connected to a tty, spawn a pager and
feed our output to it.
If the standard output is connected to a tty, spawn a pager and
feed our output to it.
+`NEED_WORK_TREE`::
+
+ Make sure there is a work tree, i.e. the command cannot act
+ on bare repositories.
+ This makes only sense when `RUN_SETUP` is also set.
+
. Add `builtin-foo.o` to `BUILTIN_OBJS` in `Makefile`.
Additionally, if `foo` is a new command, there are 3 more things to do:
. Add `builtin-foo.o` to `BUILTIN_OBJS` in `Makefile`.
Additionally, if `foo` is a new command, there are 3 more things to do:
@@
-41,8
+47,7
@@
Additionally, if `foo` is a new command, there are 3 more things to do:
. Write documentation in `Documentation/git-foo.txt`.
. Write documentation in `Documentation/git-foo.txt`.
-. Add an entry for `git-foo` to the list at the end of
- `Documentation/cmd-list.perl`.
+. Add an entry for `git-foo` to `command-list.txt`.
How a built-in is called
How a built-in is called