From 3d2adc7384e658641a74bdd5ed6069d6955ee373 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Tue, 26 Dec 2006 03:21:45 +0000 Subject: [PATCH] Autogenerated HTML docs for v1.5.0-rc0 --- git-add.html | 24 +++++++++++++++---- git-add.txt | 17 ++++++++++---- git-rm.html | 66 ++++++++++++++++++++++++++-------------------------- git-rm.txt | 51 +++++++++++++++++++++------------------- 4 files changed, 92 insertions(+), 66 deletions(-) diff --git a/git-add.html b/git-add.html index f7e641f61..47add7e9a 100644 --- a/git-add.html +++ b/git-add.html @@ -272,7 +272,7 @@ git-add(1) Manual Page

SYNOPSIS

-

git-add [-n] [-v] [--interactive] [--] <file>…

+

git-add [-n] [-v] [-f] [--interactive] [--] <file>…

DESCRIPTION

@@ -287,8 +287,10 @@ subsequent changes to already added content if it is not added again before the commit.

The git status command can be used to obtain a summary of what is included for the next commit.

-

This command only adds non-ignored files, to add ignored files use -"git update-index --add".

+

This command can be used to add ignored files with -f (force) +option, but they have to be +explicitly and exactly specified from the command line. File globbing +and recursive behaviour do not add ignored files.

Please see git-commit(1) for alternative ways to add content to a commit.

@@ -300,7 +302,11 @@ commit.

- Files to add content from. + Files to add content from. Fileglobs (e.g. *.c) can + be given to add all matching files. Also a + leading directory name (e.g. dir to add dir/file1 + and dir/file2) can be given to add all files in the + directory, recursively.

@@ -320,6 +326,14 @@ commit.

+-f +
+
+

+ Allow adding otherwise ignored files. +

+
+
--interactive
@@ -522,7 +536,7 @@ diff diff --git a/git-add.txt b/git-add.txt index 8710b3a75..95bea6637 100644 --- a/git-add.txt +++ b/git-add.txt @@ -7,7 +7,7 @@ git-add - Add file contents to the changeset to be committed next SYNOPSIS -------- -'git-add' [-n] [-v] [--interactive] [--] ... +'git-add' [-n] [-v] [-f] [--interactive] [--] ... DESCRIPTION ----------- @@ -25,8 +25,10 @@ the commit. The 'git status' command can be used to obtain a summary of what is included for the next commit. -This command only adds non-ignored files, to add ignored files use -"git update-index --add". +This command can be used to add ignored files with `-f` (force) +option, but they have to be +explicitly and exactly specified from the command line. File globbing +and recursive behaviour do not add ignored files. Please see gitlink:git-commit[1] for alternative ways to add content to a commit. @@ -35,7 +37,11 @@ commit. OPTIONS ------- ...:: - Files to add content from. + Files to add content from. Fileglobs (e.g. `*.c`) can + be given to add all matching files. Also a + leading directory name (e.g. `dir` to add `dir/file1` + and `dir/file2`) can be given to add all files in the + directory, recursively. -n:: Don't actually add the file(s), just show if they exist. @@ -43,6 +49,9 @@ OPTIONS -v:: Be verbose. +-f:: + Allow adding otherwise ignored files. + \--interactive:: Add modified contents in the working tree interactively to the index. diff --git a/git-rm.html b/git-rm.html index 0c00258a5..0b2a6e853 100644 --- a/git-rm.html +++ b/git-rm.html @@ -272,13 +272,14 @@ git-rm(1) Manual Page

SYNOPSIS

-

git-rm [-f] [-n] [-v] [--] <file>…

+

git-rm [-f] [-n] [-r] [--cached] [--] <file>…

DESCRIPTION

-

A convenience wrapper for git-update-index --remove. For those coming -from cvs, git-rm provides an operation similar to "cvs rm" or "cvs -remove".

+

Remove files from the working tree and from the index. The +files have to be identical to the tip of the branch, and no +updates to its contents must have been placed in the staging +area (aka index).

OPTIONS

@@ -288,8 +289,11 @@ remove".

- Files to remove from the index and optionally, from the - working tree as well. + Files to remove. Fileglobs (e.g. *.c) can be given to + remove all matching files. Also a leading directory name + (e.g. dir to add dir/file1 and dir/file2) can be + given to remove all files in the directory, recursively, + but this requires -r option to be given for safety.

@@ -297,7 +301,7 @@ remove".

- Remove files from the working tree as well as from the index. + Override the up-to-date check.

@@ -310,11 +314,12 @@ remove".

--v +-r

- Be verbose. + Allow recursive removal when a leading directory name is + given.

@@ -327,29 +332,24 @@ remove".

for command-line options).

+
+--cached +
+
+

+ This option can be used to tell the command to remove + the paths only from the index, leaving working tree + files. +

+

DISCUSSION

-

The list of <file> given to the command is fed to git-ls-files -command to list files that are registered in the index and -are not ignored/excluded by $GIT_DIR/info/exclude file or -.gitignore file in each directory. This means two things:

-
    -
  1. -

    -You can put the name of a directory on the command line, and the - command will remove all files in it and its subdirectories (the - directories themselves are never removed from the working tree); -

    -
  2. -
  3. -

    -Giving the name of a file that is not in the index does not - remove that file. -

    -
  4. -
+

The list of <file> given to the command can be exact pathnames, +file glob patterns, or leading directory name. The command +removes only the paths that is known to git. Giving the name of +a file that you have not told git about does not remove that file.

EXAMPLES

@@ -373,10 +373,10 @@ git-rm -f git-*.sh

Remove all git-*.sh scripts that are in the index. The files - are removed from the index, and (because of the -f option), - from the working tree as well. Because this example lets the - shell expand the asterisk (i.e. you are listing the files - explicitly), it does not remove subdir/git-foo.sh. + are removed from the index, and from the working + tree. Because this example lets the shell expand the + asterisk (i.e. you are listing the files explicitly), it + does not remove subdir/git-foo.sh.

@@ -399,7 +399,7 @@ git-rm -f git-*.sh
diff --git a/git-rm.txt b/git-rm.txt index 66fc478f5..3a8f279e1 100644 --- a/git-rm.txt +++ b/git-rm.txt @@ -7,51 +7,54 @@ git-rm - Remove files from the working tree and from the index SYNOPSIS -------- -'git-rm' [-f] [-n] [-v] [--] ... +'git-rm' [-f] [-n] [-r] [--cached] [--] ... DESCRIPTION ----------- -A convenience wrapper for git-update-index --remove. For those coming -from cvs, git-rm provides an operation similar to "cvs rm" or "cvs -remove". +Remove files from the working tree and from the index. The +files have to be identical to the tip of the branch, and no +updates to its contents must have been placed in the staging +area (aka index). OPTIONS ------- ...:: - Files to remove from the index and optionally, from the - working tree as well. + Files to remove. Fileglobs (e.g. `*.c`) can be given to + remove all matching files. Also a leading directory name + (e.g. `dir` to add `dir/file1` and `dir/file2`) can be + given to remove all files in the directory, recursively, + but this requires `-r` option to be given for safety. -f:: - Remove files from the working tree as well as from the index. + Override the up-to-date check. -n:: Don't actually remove the file(s), just show if they exist in the index. --v:: - Be verbose. +-r:: + Allow recursive removal when a leading directory name is + given. \--:: This option can be used to separate command-line options from the list of files, (useful when filenames might be mistaken for command-line options). +\--cached:: + This option can be used to tell the command to remove + the paths only from the index, leaving working tree + files. + DISCUSSION ---------- -The list of given to the command is fed to `git-ls-files` -command to list files that are registered in the index and -are not ignored/excluded by `$GIT_DIR/info/exclude` file or -`.gitignore` file in each directory. This means two things: - -. You can put the name of a directory on the command line, and the - command will remove all files in it and its subdirectories (the - directories themselves are never removed from the working tree); - -. Giving the name of a file that is not in the index does not - remove that file. +The list of given to the command can be exact pathnames, +file glob patterns, or leading directory name. The command +removes only the paths that is known to git. Giving the name of +a file that you have not told git about does not remove that file. EXAMPLES @@ -69,10 +72,10 @@ subdirectories of `Documentation/` directory. git-rm -f git-*.sh:: Remove all git-*.sh scripts that are in the index. The files - are removed from the index, and (because of the -f option), - from the working tree as well. Because this example lets the - shell expand the asterisk (i.e. you are listing the files - explicitly), it does not remove `subdir/git-foo.sh`. + are removed from the index, and from the working + tree. Because this example lets the shell expand the + asterisk (i.e. you are listing the files explicitly), it + does not remove `subdir/git-foo.sh`. See Also -------- -- 2.26.2