The --ignored-paths argument is now stored as
"svn-remote.$REMOTE_NAME.ignore-paths" in the config file.
[ew: edited subject and message]
Signed-off-by: Ben Jackson <ben@ben.com>
Acked-by: Eric Wong <normalperson@yhbt.net>
The --ignore-paths option to fetch is very useful for working on a subset
of a SVN repository. For proper operation, every command that causes a
fetch (explicit or implied) must include a matching --ignore-paths option.
This patch adds a persistent svn-remote.$repo_id.ignore-paths config by
promoting Fetcher::is_path_ignored to a member function and initializing
$self->{ignore_regex} in Fetcher::new. Command line --ignore-paths is
still recognized and acts in addition to the config value.
Signed-off-by: Ben Jackson <ben@ben.com>
Acked-by: Eric Wong <normalperson@yhbt.net>
* maint:
Change double quotes to single quotes in message
Documentation: clarify .gitattributes search
git-checkout.txt: clarify that <branch> applies when no path is given.
git-checkout.txt: fix incorrect statement about HEAD and index
Conflicts:
Documentation/git-checkout.txt
Most of the time when we give branch name in the message, we quote it
inside a pair of single-quotes. git-checkout uses double-quotes; this
patch corrects the inconsistency.
Signed-off-by: Jari Aalto <jari.aalto@cante.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
* bs/maint-1.6.0-tree-walk-prefix:
match_tree_entry(): a pathspec only matches at directory boundaries
tree_entry_interesting: a pathspec only matches at directory boundary
* cb/maint-merge-recursive-submodule-fix:
simplify output of conflicting merge
update cache for conflicting submodule entries
add tests for merging with submodules
* jc/shared-literally:
t1301: loosen test for forced modes
set_shared_perm(): sometimes we know what the final mode bits should look like
move_temp_to_file(): do not forget to chmod() in "Coda hack" codepath
Move chmod(foo, 0444) into move_temp_to_file()
"core.sharedrepository = 0mode" should set, not loosen
* sb/format-patch-patchname:
format_sanitized_subject: Don't trim past initial length of strbuf
log-tree: fix patch filename computation in "git format-patch"
format-patch: --numbered-files and --stdout aren't mutually exclusive
format-patch: --attach/inline uses filename instead of SHA1
format-patch: move get_patch_filename() into log-tree
format-patch: pass a commit to reopen_stdout()
format-patch: construct patch filename in one function
pretty.c: add %f format specifier to format_commit_message()
When merging merge bases during a recursive merge we do not want to
leave any unmerged entries. Otherwise we cannot create a temporary
tree for the recursive merge to work with.
We failed to do so in case of a submodule conflict between merge
bases, causing a NULL pointer dereference in the next step of the
recursive merge.
Signed-off-by: Clemens Buchacher <drizzd@aon.at>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commit 6e18251 (send-email: refactor and ensure prompting doesn't loop
forever) introduced an ask function, which unfortunately had a nasty
bug. This caused it not to accept anything but the default reply to the
"Who should the emails appear to be from?" prompt, and nothing but
ctrl-d to the "Who should the emails be sent to?" and "Message-ID to be
used as In-Reply-To for the first email?" prompts.
This commit corrects the issues and adds a test to confirm the fix.
Signed-off-by: Jay Soffian <jaysoffian@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
While 'git checkout <submodule>' should not update the submodule's
working directory, it should update the index. This is in line with
how submodules are handled in the rest of Git.
While at it, test 'git reset [<commit>] <submodule>', too.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
sanitize_address assumes that quoted addresses (e.g., "first last"
<first.last@example.com) do not need rfc2047 encoding, but this is
not always the case.
For example, various places in send-email extract addresses using
parse_address_line. parse_address_line returns the addresses already
quoted (e.g., "first last" <first.last@example.com), but not rfc2047
encoded.
This patch makes sanitize_address stricter about what needs rfc2047
encoding and adds a test demonstrating where I noticed the problem.
Signed-off-by: Jay Soffian <jaysoffian@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commit c18f75a (send-email: add tests for refactored prompting, 2009-03-28)
added two tests which went interactive under the dash shell.
This patch corrects the issue, reported by Björn Steinbrink.
Signed-off-by: Jay Soffian <jaysoffian@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
* ef/fast-export:
builtin-fast-export.c: handle nested tags
builtin-fast-export.c: fix crash on tagged trees
builtin-fast-export.c: turn error into warning
test-suite: adding a test for fast-export with tag variants
* jc/maint-1.6.0-keep-pack:
pack-objects: don't loosen objects available in alternate or kept packs
t7700: demonstrate repack flaw which may loosen objects unnecessarily
Remove --kept-pack-only option and associated infrastructure
pack-objects: only repack or loosen objects residing in "local" packs
git-repack.sh: don't use --kept-pack-only option to pack-objects
t7700-repack: add two new tests demonstrating repacking flaws
Conflicts:
t/t7700-repack.sh
Previously the code did a simple prefix match, which means that a path in
a directory "frotz/" would have matched with pathspec "f".
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Previously the code did a simple prefix match, which means that a
path in a directory "frotz/" would have matched with pathspec "f".
Signed-off-by: Björn Steinbrink <B.Steinbrink@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This makes sure that local branches, when followed using --track, behave
the same as remote ones (e.g. differences being reported by git status
and git checkout). This fixes 1 known failure.
The fix is done within branch_get(): The first natural candidate,
namely remote_find_tracking(), does not have all the necessary info
because in general there is no remote struct for '.', and we don't want
one because it would show up in other places as well.
branch_get(), on the other hand, has access to merge_names[] (in
addition to merge[]) and therefore can set up the followed branch
easily.
Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commit 6e18251 made the "Send this email?" prompt assume yes if confirm
= "inform" when it was unable to get a valid response. However, the
"yes" assumption only worked correctly for the first email. This commit
fixes the issue and confirms the fix by modifying the existing test for
the prompt to send multiple emails.
Reported by Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Jay Soffian <jaysoffian@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
One of the aspects of the test checked explicitly for the
g+s bit to be set on created directories. However, this is
only the means to an end (the "end" being having the correct
group set). And in fact, on systems where
DIR_HAS_BSD_GROUP_SEMANTICS is set, we do not even need to
use this "means" at all, causing the test to fail.
This patch removes that part of the test. In an ideal world
it would be replaced by a test to check that the group was
properly assigned, but that is difficult to automate because
it requires the user running the test suite be a member of
multiple groups.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
When tags that points to tags are passed to fast-export, an error is given,
saying "Tag [TAGNAME] points nowhere?". This fix calls parse_object() on the
object before referencing it's tag, to ensure the tag-info is fully initialized.
In addition, it inserts a comment to point out where nested tags are handled.
This is consistent with the comment for signed tags.
Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
If a tag object points to a tree (or another unhandled type), the commit-
pointer is left uninitialized and later dereferenced. This patch adds a
default case to the switch that issues a warning and skips the object.
Signed-off-by: Erik Faye-Lund <kusmabite@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Bring documentation in test-lib and clean target
in Makefile in-line with abc5d372.
Signed-off-by: Emil Sit <sit@emilsit.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
format-patch supports the format.headers configuration for adding
arbitrary email headers to the patches it outputs. This patch adds
support for an --add-header argument which makes the same feature
available from the command line. This is useful when the content of
custom email headers must change from branch to branch.
This patch has been sponsored by Grant Street Group
Signed-off-by: Michael Hendricks <michael@ndrix.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This fixes the behaviour of octal notation to how it is defined in the
documentation, while keeping the traditional "loosen only" semantics
intact for "group" and "everybody".
Three main points of this patch are:
- For an explicit octal notation, the internal shared_repository variable
is set to a negative value, so that we can tell "group" (which is to
"OR" in 0660) and 0660 (which is to "SET" to 0660);
- git-init did not set shared_repository variable early enough to affect
the initial creation of many files, notably copied templates and the
configuration. We set it very early when a command-line option
specifies a custom value.
- Many codepaths create files inside $GIT_DIR by various ways that all
involve mkstemp(), and then call move_temp_to_file() to rename it to
its final destination. We can add adjust_shared_perm() call here; for
the traditional "loosen-only", this would be a no-op for many codepaths
because the mode is already loose enough, but with the new behaviour it
makes a difference.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
According to the documentation, it is perfectly okay to follow local
branches using the --track option. Introduce a test which checks whether
they behave the same. Currently one test fails.
Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
* jc/attributes-checkout:
Add a test for checking whether gitattributes is honored by checkout.
Read attributes from the index that is being checked out
When exporting a subset of commits on a branch that do not go back to a
root commit (e.g. master~2..master), we still want each exported commit to
have the same files in the exported tree as in the original tree.
Previously, when given such a range, we would omit master~2 as a parent of
master~1, but we would still diff against master~2 when selecting the list
of files to include in master~1. This would result in only files that
had changed in the given range showing up in the resulting export. In such
cases, we should diff master~1 against the root instead (i.e. use
diff_root_tree_sha1 instead of diff_tree_sha1).
There's a special case to consider here: incremental exports (i.e. exports
where the --import-marks flag is specified). If master~2 is an imported
mark, then we still want to diff master~1 against master~2 when selecting
the list of files to include.
We can handle all cases, including the special case, by just checking
whether master~2 corresponds to a known object mark when deciding what to
diff against.
Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
The implementation of exec on Windows is just a rough approximation of the
POSIX behavior. In particular, no real process "overlay" happens (a new
process is spawned instead and the parent process waits until the child
terminates). In particular, the process ID cannot be taken by the exec'd
process. But there is one test in t7502-commit.sh that depends on this.
We have to skip it on Windows.
Signed-off-by: Johannes Sixt <j6t@kdbg.org>
The test sets up various shell scripts and uses them as commit message
editors. On Windows, we need a shebang line in order to recognize the
files as executable shell scripts. This adds it.
Signed-off-by: Johannes Sixt <j6t@kdbg.org>
* js/windows-tests:
t0060: fix whitespace in "wc -c" invocation
t5503: GIT_DEBUG_SEND_PACK is not supported on MinGW
t7004: Use prerequisite tags to skip tests that need gpg
Use prerequisites to skip tests that need unzip
t3700: Skip a test with backslashes in pathspec
Skip tests that require a filesystem that obeys POSIX permissions
t0060: Fix tests on Windows
Use prerequisite tags to skip tests that depend on symbolic links
t9100, t9129: Use prerequisite tags for UTF-8 tests
t5302: Use prerequisite tags to skip 64-bit offset tests
Skip tests that fail if the executable bit is not handled by the filesystem
t3600: Use test prerequisite tags
test-lib: Infrastructure to test and check for prerequisites
t0050: Check whether git init detected symbolic link support correctly
Tests on Windows: $(pwd) must return Windows-style paths
test-lib: Work around missing sum on Windows
test-lib: Work around incompatible sort and find on Windows
Conflicts:
t/t3000-ls-files-others.sh
Some platforms like to stick extra whitespace in the output
of "wc -c"; using the result without quotes gets the shell
to collapse the whitespace.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
For example:
git format-patch --numbered-files --stdout --attach HEAD~~
will create two messages with files 1 and 2 attached respectively.
There is no effect when using --numbered-files and --stdout together
without an --attach or --inline, the --numbered-files option will be
ignored. Add a test to show this.
Signed-off-by: Stephen Boyd <bebarino@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Currently when format-patch is used with --attach or --inline the patch
attachment has the SHA1 of the commit for its filename. This replaces
the SHA1 with the filename used by format-patch when outputting to
files.
Fix tests relying on the SHA1 output and add a test showing how the
--suffix option affects the attachment filename output.
Signed-off-by: Stephen Boyd <bebarino@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>