1
0
mirror of https://github.com/git/git.git synced 2024-09-30 07:51:31 +02:00
Commit Graph

2998 Commits

Author SHA1 Message Date
J. Bruce Fields
c2bc6e404d Documentation: clarify fetch parameter descriptions.
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-12 22:03:11 -08:00
Junio C Hamano
87758f975b show-branch: handle [] globs as well.
Earlier only '?' and '*' signalled the command that what the
user has given is a glob pattern.  This prevented us to say:

	$ git show-branch 'v0.99.[0-3]'

Now we notice '[' as well, so the above would work.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-11 15:36:07 -08:00
Junio C Hamano
2c817df25d name-rev: do not omit leading components of ref name.
In a repository with mainto/1.0 (to keep maintaining the 1.0.X
series) and fixo/1.0 (to keep fixes that apply to both 1.0.X
series and upwards) branches, "git-name-rev mainto/1.0" answered
just "1.0" making things ambiguous.  Show refnames unambiguously
like show-branch does.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-11 14:47:20 -08:00
Junio C Hamano
a94d9948da update-index: work with c-quoted name
update-index --stdin did not work with c-style quoted names even though
update-index --index-info did.  This fixes the inconsistency.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-11 13:36:45 -08:00
Johannes Schindelin
d5a6aafc90 glossary: explain "master" and "origin"
If you are a long time git user/developer, you forget that to a new git
user, these words have not the same meaning as to you.

[jc: with updates from J. Bruce Fields.]

Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-10 16:02:54 -08:00
Junio C Hamano
6f2eacfeb2 mailsplit: allow empty input from stdin
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-07 21:26:30 -08:00
Junio C Hamano
013049c985 revert/cherry-pick: handle single quote in author name.
The same fix as aa66c7ec77d474b737da607d6cb2d07f56628def is
needed here.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-07 20:45:11 -08:00
Yann Dirson
5f815e5922 Fix git-format-patch usage string wrt output modes.
--stdout was not mentionned, and the description for the case where -o
was not given was thus incomplete.

Signed-off-by: Yann Dirson <ydirson@altern.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-07 18:17:38 -08:00
Yann Dirson
36071af305 Fix typo in debug stanza of t2001
Signed-off-by: Yann Dirson <ydirson@altern.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-07 18:13:44 -08:00
Junio C Hamano
3ac0ebbba4 tar-tree: finish honoring extractor's umask in git-tar-tree.
Earlier commit 38ec15a973a1f075f0d94d130b0ef279562921cd forgot
to apply the same principle of not forcing go-w to the base
directory when specified.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-07 15:11:11 -08:00
Junio C Hamano
8f1d2e6f49 [PATCH] Compilation: zero-length array declaration.
ISO C99 (and GCC 3.x or later) lets you write a flexible array
at the end of a structure, like this:

	struct frotz {
		int xyzzy;
		char nitfol[]; /* more */
	};

GCC 2.95 and 2.96 let you to do this with "char nitfol[0]";
unfortunately this is not allowed by ISO C90.

This declares such construct like this:

	struct frotz {
		int xyzzy;
		char nitfol[FLEX_ARRAY]; /* more */
	};

and git-compat-util.h defines FLEX_ARRAY to 0 for gcc 2.95 and
empty for others.

If you are using a C90 C compiler, you should be able
to override this with CFLAGS=-DFLEX_ARRAY=1 from the
command line of "make".

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-07 10:51:06 -08:00
Junio C Hamano
3be7098ce4 prune: do not show error from pack-redundant when no packs are found.
When there is no pack yet, git-prune leaked an error message
from "git-pack-redundant --all" which complained that there is
no pack.  Squelch the annoying message.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-07 00:29:48 -08:00
Junio C Hamano
7d0e65b892 Retire debian/ directory.
The official maintainer is keeping up-to-date quite well, and now
the older Debian is supported with backports.org, there is no reason
for me to keep debian/ directory around here.

I have not been building and publishing debs since 1.0.4 anyway.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-06 19:18:12 -08:00
Junio C Hamano
476e801111 unpack-objects: default to quiet if stderr is not a tty.
This would help cron/at jobs that run send-pack to mirror
repositories.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-06 18:53:16 -08:00
Joe English
34c99da2a4 Substitute "/" with $opt_s in tag names as well as branch names
In 'git cvsimport' changes "/" to "-" (or $opt_s) in branch names,
but not in tag names, which is inconsistent.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-06 14:27:47 -08:00
Yann Dirson
576cfc86fc Teach cvsexportcommit to add new files
"cvs add" support was already there, but the "unknown" status
returned when querying a file not yet known to cvs caused the
script to abort prematurely.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-06 14:27:47 -08:00
Jon Loeliger
c1fe2fe4fe Fix git-symbolic-ref typo in git.txt.
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 20:29:52 -08:00
Andreas Ericsson
da6bf70ebf git: grok 'help' to mean '--help'.
Most other scm's understand it, most users expect it and it's an easy fix.

Signed-off-by: Andreas Ericsson <ae@op5.se>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 20:28:52 -08:00
Eric Wong
2ed8e622bf Documentation/git-svnimport: document -T and -t switches correctly
The -T and -t switches are swapped in the documentation and actual
code.  I've made the documentation match the code.

Signed-off-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 20:28:19 -08:00
Eric Wong
2961e0ee8b svnimport: support repositories requiring SSL authentication
I looked at svn-mirror to see how it did this, seems about right.
"It works for me" when using it against https://svn.musicpd.org

tested command-line: git-svnimport -C mpc -i -m -v  \
	-T mpc/trunk -b mpc/branches -t mpc/tags https://svn.musicpd.org

Signed-off-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 20:28:14 -08:00
Junio C Hamano
6ce183216d t3300: skip when filesystem does not like TAB in filenames.
Instead of checking Cygwin explicitly, see if the filesystem lets us
create funny filenames.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 20:14:40 -08:00
Junio C Hamano
aa66c7ec77 format-patch/commit: Quote single quote in the author name properly.
Noticed by Kyle McMartin.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 20:02:33 -08:00
Junio C Hamano
81214e4ddf git-fetch --tags: reject malformed tags.
When the other end was prepared with older git and has tags that
do not follow the naming convention (see check-ref-format), do not
barf but simply reject to copy them.

Initial fix by Simon Richter, but done differently.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 19:42:12 -08:00
Jonas Fonseca
353ce81597 Wrap synopsis lines and use [verse] to keep formatting
In addition, also fixes a few synopses to be more consistent and a gitlink.

Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 18:44:28 -08:00
Alex Riesen
6ff0b1c56c use GIT_DIR instead of /var/tmp
Not every system (will not one microsoft windows system) have /var/tmp,
whereas using GIT_DIR for random temporary files is more or less established.

Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:24:51 -08:00
Alex Riesen
2ccd2027b0 trivial: check, if t/trash directory was successfully created
and was successfully entered. Otherwise git-init-db will create it directly
in the working directory (t/) which can be dangerous.

Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:24:47 -08:00
Alex Riesen
10ae7d86c1 trivial: .gitignore precompiled python modules
Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:24:42 -08:00
Alex Riesen
b484ef28fb trivial: use git-repo-config to detect how to run tests in the test repository
Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:23:46 -08:00
Alex Riesen
e58b97af31 trivial: use git-repo-config to detect if the test can be run on the repository
Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:23:44 -08:00
Alex Riesen
31f883d1b8 trivial: remove the dots at the end of file names from merge-one-file
to make the output more friendly to mouse copy-paste.

Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:23:41 -08:00
Alex Riesen
50b4e0c178 trivial: clarify, what are the config's user.name and user.email about
Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:23:21 -08:00
Alex Riesen
b6ae5409ea trivial: typo in git-commit.sh
Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:23:16 -08:00
Alex Riesen
88fb958baa use result of open(2) to check for presence
Not that the stat against open race would matter much in this context,
but that simplifies
the code a bit. Also some diagnostics added (why the open failed)

Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:22:51 -08:00
Alex Riesen
d9e08be9d5 fix potential deadlock in create_one_file
It can happen if the temporary file already exists (i.e. after a panic
and reboot).

Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:22:49 -08:00
Alex Riesen
781411ed46 trivial: O_EXCL makes O_TRUNC redundant
Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:22:47 -08:00
Alex Riesen
7f272ca80c trivial: retval of waitpid is not errno
...but is used as such and passed to strerror.

Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:22:45 -08:00
Linus Torvalds
b73cebf437 Fix nasty approxidate bug
Stupid me.

If approxidate ends up with a month that is ahead of the current month, it
decrements the year to last year.

Which is correct, and means that "last december" does the right thing.

HOWEVER. It should only do so if the year is the same as the current year.

Without this fix, "5 days ago" ends up being in 2004, because it first
decrements five days, getting us to December 2005 (correct), but then it
also ends up decrementing the year once more to turn that December into
"last year" (incorrect, since it already _was_ last year).

Duh. Pass me a donut.

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:22:43 -08:00
Amos Waterland
0a15217184 AIX compile fix for repo-config.c
AIX 5 has a /usr/include/regex.h containing this code:

 #ifdef  _NO_PROTO
 extern  char    *regex();
 extern  char    *regcmp();
 #else /* _NO_PROTO */
 extern  char    *regex(const char *, const char *, ...);
 extern  char    *regcmp(const char *, ...);
 #endif  /* _NO_PROTO */

This means that repo-config.c is trying to redefine the `regex' symbol.
Here is a simple patch that just uses `regexp' as the symbol name instead.

Signed-off-by: Amos Waterland <apw@us.ibm.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:22:37 -08:00
Jonas Fonseca
8b32572c74 git-init-db(1): Describe --shared and the idempotent nature of init-db
Based on the recent discussion on the mailing list.

Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05 17:22:31 -08:00
Junio C Hamano
4e7a2eccc2 ?alloc: do not return NULL when asked for zero bytes
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-29 01:33:40 -08:00
Junio C Hamano
82f9d58a39 code comments: spell
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-29 01:32:56 -08:00
Junio C Hamano
89438677ab Documentation: spell.
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-29 01:32:56 -08:00
Gerrit Pape
f1ec72ba1e Fix skipping merge-order test with NO_OPENSSL=1.
Move git-rev-list --merge-order usage check for 'OpenSSL not linked' after
test 1; we cannot trigger this unless we try to actually use --merge-order
by giving some ref, and we do not have any ref until we run the first test
to create commits.

Signed-off-by: Gerrit Pape <pape@smarden.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-28 11:09:53 -08:00
Junio C Hamano
36cd2cc7d9 Do not mark tags fetched via --tags flag as mergeable
Otherwise "git pull --tags" would mistakenly try to merge all of
them, which is never what the user wants.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-27 11:52:51 -08:00
Junio C Hamano
e9add36007 Fix bogus tests on rev-list output.
These tests seem to mean checking the output with expected
result, but was not doing its handrolled test helper function.

Also fix the guard to workaround wc output that have whitespace
padding, which was broken but not exposed because the test was
not testing it ;-).

Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-27 11:08:57 -08:00
Junio C Hamano
8eafa3da62 Guard a test against wc that pads its output with whitespace
Spotted by Johannes.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-27 11:08:57 -08:00
Sam Ravnborg
08337a97a2 copy_fd: close ifd on error
In copy_fd when write fails we ought to close input file descriptor.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-27 10:49:25 -08:00
Johannes Schindelin
975b31dc6e Handle symlinks graciously
This patch converts a stat() to an lstat() call, thereby fixing the case
when the date of a symlink was not the same as the one recorded in the
index. The included test case demonstrates this.

This is for the case that the symlink points to a non-existing file. If
the file exists, worse things than just an error message happen.

Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-26 18:33:27 -08:00
Junio C Hamano
c97451ce09 t5300: avoid false failures.
Johannes found that the test has 1/256 chance of falsely
producing an uncorrupted idx file, causing the check to detect
corruption fail.  Now we have 1/2^160 chance of false failure
;-).

Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-26 18:23:41 -08:00
Junio C Hamano
7e4a2a8483 avoid asking ?alloc() for zero bytes.
Avoid asking for zero bytes when that change simplifies overall
logic.  Later we would change the wrapper to ask for 1 byte on
platforms that return NULL for zero byte request.

Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-26 17:23:59 -08:00