"git pull/fetch" that gets explicit refspecs from the command line should
not update configured tracking refs.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
* wc/add-i:
git-add -i: add help text for list-and-choose UI
add -i: allow prefix highlighting for "Add untracked" as well.
Highlight keyboard shortcuts in git-add--interactive
Document all help keys in "git add -i" patch mode.
Add "--patch" option to git-add--interactive
add -i: Fix running from a subdirectory
builtin-add: fix command line building to call interactive
git-add -i: allow multiple selection in patch subcommand
Add path-limiting to git-add--interactive
Teach builtin-add to pass multiple paths to git-add--interactive
* kh/commit: (33 commits)
git-commit --allow-empty
git-commit: Allow to amend a merge commit that does not change the tree
quote_path: fix collapsing of relative paths
Make git status usage say git status instead of git commit
Fix --signoff in builtin-commit differently.
git-commit: clean up die messages
Do not generate full commit log message if it is not going to be used
Remove git-status from list of scripts as it is builtin
Fix off-by-one error when truncating the diff out of the commit message.
builtin-commit.c: export GIT_INDEX_FILE for launch_editor as well.
Add a few more tests for git-commit
builtin-commit: Include the diff in the commit message when verbose.
builtin-commit: fix partial-commit support
Fix add_files_to_cache() to take pathspec, not user specified list of files
Export three helper functions from ls-files
builtin-commit: run commit-msg hook with correct message file
builtin-commit: do not color status output shown in the message template
file_exists(): dangling symlinks do exist
Replace "runstatus" with "status" in the tests
t7501-commit: Add test for git commit <file> with dirty index.
...
* sp/refspec-match:
refactor fetch's ref matching to use refname_match()
push: use same rules as git-rev-parse to resolve refspecs
add refname_match()
push: support pushing HEAD to real branch name
POSIX says that exit status "0" means that "unset" successfully unset
the variable. However, it is kind of ambiguous if an environment
variable which was not set could be successfully unset.
At least the default shell on HP-UX insists on reporting an error in
such a case, so just ignore the exit status of "unset".
[Dscho: extended the patch to git-submodule.sh, as Junio realized that
this is the only other place where we check the exit status of "unset".]
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: İsmail Dönmez <ismail@pardus.org.tr>
Tested-by: Martin Koegler <mkoegler@auto.tuwien.ac.at>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-cvsimport won't run at all with less than cvsps 2.1, because it
lacks the -A flag. But there's no point in preventing people who have an
old cvsps from running the full testsuite.
Tested-by: A Large Angry SCM <gitzilla@gmail.com>
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
The remotes2config.sh script replaced all 'unsafe' characters in repo
name with '.'; include '-' in the 'safe' characters set (the set is
probably even larger).
Script required also space after "URL:", "Push:" and "Pull:" in
remotes file. This for example made the following remote
URL: git://git.kernel.org/pub/scm/git/git.git
Pull: refs/heads/master:refs/heads/origin
Pull:+refs/heads/pu:refs/heads/pu
miss 'pu' branch (forced branch) in config file after conversion.
Allow for any number of whitespace after "URL:", "Push:", "Pull:".
Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Makefile uses $(PERL_PATH) but Documentation/Makefile uses "perl"; that
means the two Makefiles can use two different Perl installations.
Teach Documentation/Makefile to use PERL_PATH that is exported from the
toplevel Makefile, and give a sane fallback for people who run "make"
from Documentation directory.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Earlier, ':/<oneline-prefix>' would not work (i.e. die) with commands that
set save_commit_buffer = 0, such as blame, describe, pack-objects, reflog
and bundle.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
The name 'verbatim' describes much better what this mode does with
signed tags. While at it, fix the documentation what it actually
does.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
As well as allowing a default http.proxy option, allow it to be set
per-remote.
Signed-off-by: Sam Vilain <sam.vilain@catalyst.net.nz>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Option -i|--info for "git-help" is documented only in the new
"git-help.txt" man page, but this new man page is referenced
from the "--help" option documentation in the "git.txt" man page.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
"git help --info subcommand" will now call "info git-subcommand".
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
The http_proxy / HTTPS_PROXY variables used by curl to control
proxying may not be suitable for git. Allow the user to override them
in the configuration file.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Now that str_buf takes care of all the allocations, there is
no more gain to pass an argument count.
So this patch removes the "count" argument from:
- "sq_quote_argv"
- "trace_argv_printf"
and all the callers.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
The install-sh script as shipped with automake requires a space between
the -m switch and its argument. Since this is also the regular way of
doing it with other install implementations this change inserts the
missing space in all makefiles.
Signed-off-by: Robert Schiele <rschiele@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
It does not usually make sense to record a commit that has the exact
same tree as its sole parent commit and that is why git-commit prevents
you from making such a mistake, but when data from foreign scm is
involved, it is a different story. We are equipped to represent such an
(perhaps insane, perhaps by mistake, or perhaps done on purpose) empty
change, and it is better to represent it bypassing the safety valve for
native use.
This is primarily for use by foreign scm interface scripts.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
It does not usually make sense to record a commit that has the exact
same tree as its sole parent commit and that is why git-commit prevents
you from making such a mistake, but when data from foreign scm is
involved, it is a different story. We are equipped to represent such an
(perhaps insane, perhaps by mistake, or perhaps done on purpose) empty
change, and it is better to represent it bypassing the safety valve for
native use.
This is primarily for use by foreign scm interface scripts.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Normally, it should not be allowed to generate an empty commit. A merge
commit generated with git 'merge -s ours' does not change the tree (along
the first parent), but merges are not "empty" even if they do not change
the tree. Hence, commit 8588452ceb allowed to amend a merge commit that
does not change the tree, but 4fb5fd5d30 disallowed it again in an
attempt to avoid that an existing commit is amended such that it becomes
empty. With this change, a commit can be edited (create a new one or amend
an existing one) either if there are changes or if there are at least two
parents.
Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Normally, it should not be allowed to generate an empty commit. A merge
commit generated with git 'merge -s ours' does not change the tree (along
the first parent), but merges are not "empty" even if they do not change
the tree. Hence, we should be careful not to forbid this case.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
The code tries to collapse identical leading components
between the prefix and the path. So if we're in "dir1", the
path "dir1/file" should become just "file". However, we were
ending up with "../dir1/file". The included test expected
the wrong output.
The "len" parameter to quote_path can be negative to mean
"this is a NUL terminated string". Simply count it so that
the loop can rely on it being the length of the path.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git status shares the same usage information as git commit since it
shows what would be committed if the same options are given. However,
when displaying the usage information for git status it should say it
is for git status not git commit.
Signed-off-by: Shawn Bohrer <shawn.bohrer@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Introduce fmt_name() specifically meant for formatting the name and
email pair, to add signed-off-by value. This reverts parts of
13208572fb (builtin-commit: fix --signoff)
so that an empty datestamp string given to fmt_ident() by mistake will
error out as before.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
* wc/rebase-insn:
Mention that git-rm can be an appropriate resolution as well as git-add.
revert/cherry-pick: Allow overriding the help text by the calling Porcelain
Previusly, there was only a 16x16 image, which looked very distorted.
Here we add a 32x32 version, and also make the image sharper.
Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
The install-sh script as shipped with automake requires a space between
the -m switch and its argument. Since this is also the regular way of
doing it with other install implementations this change inserts the
missing space.
Signed-off-by: Robert Schiele <rschiele@gmail.com>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Any program using getopt or getopt_long will stop processing options
once a non-option argument has been encountered, if POSIXLY_CORRECT is
set. Therefore, reorder the command-line arguments to put options
first, so that the msgfmt call works in this scenario.
Signed-off-by: brian m. carlson <sandals@crustytoothpaste.ath.cx>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
This program dumps (parts of) a git repository in the format that
fast-import understands.
For clarity's sake, it does not use the 'inline' method of specifying
blobs in the commits, but builds the blobs before building the commits.
Since signed tags' signatures will not necessarily be valid (think
transformations after the export, or excluding revisions, changing
the history), there are 4 modes to handle them: abort (default),
ignore, warn and strip. The latter just turns the tags into
unsigned ones.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Update list of build configuration variables, add references
to gitweb/INSTALL, add description of runtime and per-repository
runtime configuration.
Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
The current git-stash behaviour is very error prone to typos. For example,
if you typed "git-stash llist", git-stash would think that you wanted to
save to a stash named "llist", but in fact, you meant "git-stash list".
Signed-off-by: Kevin Leung <kevinlsk@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>