Commit Graph

6817 Commits

Author SHA1 Message Date
Vicent Marti
58eea5ebf4 Merge pull request #2358 from arthurschreiber/arthur/normalize-ref-names-on-creation
Respect core.precomposeunicode = true in more cases.
2014-05-30 15:28:05 +02:00
Arthur Schreiber
9d6c3d2853 Refs: Extend unicode test for branch creation.
This adds another assertion to ensure that the reference name inside
the git_reference struct returned by `git_branch_create` is returned as
precomposed if `core.precomposeunicode` is enabled.
2014-05-30 15:15:54 +02:00
Arthur Schreiber
1a90b1e3f1 Refs: Add a unicode test for git_branch_move.
This tests that decomposed branch names are correctly precomposed when
passed to `git_branch_move` and `core.precomposeunicode` is enabled.
2014-05-30 14:53:28 +02:00
Arthur Schreiber
824f755f10 Refs: Introduce git_refname_t. 2014-05-30 14:30:30 +02:00
Arthur Schreiber
68f9d6b283 Refs: Fix some issue when core.precomposeunicode = true.
This fixes two issues I found when core.precomposeunicode is enabled:

* When creating a reference with a NFD string, the returned
  git_reference would return this NFD string as the reference’s
  name. But when looking up the reference later, the name would
  then be returned as NFC string.
* Renaming a reference would not honor the core.precomposeunicode and
  apply no normalization to the new reference name.
2014-05-30 14:30:30 +02:00
Carlos Martín Nieto
5f0527aeac config: initialize the error
The error would be uninitialized if we take a snapshot of a config with
no backends.
2014-05-30 13:06:34 +02:00
Vicent Marti
19d77ce109 Merge pull request #2381 from ecoffey/example_log_author_filter
Add support for --author flag in example log implementation
2014-05-29 14:51:25 +02:00
Vicent Marti
31c551528b Merge pull request #2011 from libgit2/cmn/clone-local
Local clone
2014-05-29 14:50:57 +02:00
Carlos Martín Nieto
bc9f67fa85 clone: more explicit local tests
Assert the exact amount of links we expect. While there, check that a
plain git_clone() automatically chooses to link.
2014-05-29 10:06:48 +02:00
Russell Belfer
065a00e2c9 Merge pull request #2386 from Therzok/patch-2
[Blob] Update documentation for is_binary.
2014-05-28 14:51:22 -07:00
Ungureanu Marius
fda73bc5fd [Blob] Update documentation for is_binary.
filter.h tells me that we check the first 8000 bytes.
2014-05-28 22:57:21 +03:00
Eoin Coffey
33bf1b1ab0 examples/log.c: invert filtering impl and conditional 2014-05-28 09:40:08 -06:00
Carlos Martín Nieto
2614819cf3 clone: allow for linking in local clone
If requested, git_clone_local_into() will try to link the object files
instead of copying them.

This only works on non-Windows (since it doesn't have this) when both
are on the same filesystem (which are unix semantics).
2014-05-28 15:40:47 +02:00
Carlos Martín Nieto
94f742bac6 fileops: allow linking files when copying directory structures
When passed the LINK_FILES flag, the recursive copy will hardlink files
instead of copying them.
2014-05-28 15:40:22 +02:00
Carlos Martín Nieto
c1dbfcbb4a clone: add flag not to link 2014-05-28 15:40:22 +02:00
Carlos Martín Nieto
121b26738e clone: add flags to override whether to perform a local clone 2014-05-28 15:40:22 +02:00
Carlos Martín Nieto
a0b5f7854c clone: store the realpath when given a relative one
A call like git_clone("./foo", "./foo1") writes origin's url as './foo',
which makes it unusable, as they're relative to different things.

Go with git's behaviour and store the realpath as the url.
2014-05-28 15:40:22 +02:00
Carlos Martín Nieto
4386d80be1 clone: perform a "local clone" when given a local path
When git is given such a path, it will perform a "local clone",
bypassing the git-aware protocol and simply copying over all objects
that exist in the source.

Copy this behaviour when given a local path.
2014-05-28 15:40:20 +02:00
Vicent Marti
5d91bea22a Merge pull request #2380 from libgit2/cmn/index-add-modes
index: check for valid filemodes on add
2014-05-28 13:55:57 +02:00
Vicent Marti
a470a5c71b Merge pull request #2377 from libgit2/cmn/dual-os
travis: build on osx too
2014-05-28 13:51:42 +02:00
Vicent Marti
07c0eacd87 Merge pull request #2359 from e45lee/chmod-fix
Fixed permissions on template directories.
2014-05-28 13:50:58 +02:00
Vicent Marti
ab882e21b4 Merge pull request #2385 from karipe/development
Fix compile error on Visual Studio
2014-05-28 13:49:38 +02:00
Vicent Marti
63e8c3fde2 Merge pull request #2337 from ethomson/merge_ff
Introduce GIT_MERGE_CONFIG_* for merge.ff settings
2014-05-28 13:47:55 +02:00
Edward Thomson
eff531e103 Modify GIT_MERGE_CONFIG -> GIT_MERGE_PREFERENCE 2014-05-27 20:58:20 -05:00
Edward Thomson
de3f851ec4 Staticify merge_config 2014-05-27 20:49:24 -05:00
Edward Thomson
22ab888178 Use a config snapshot 2014-05-27 20:49:22 -05:00
Edward Thomson
a3622ba6cc Move GIT_MERGE_CONFIG_* to its own enum 2014-05-27 20:49:20 -05:00
Edward Thomson
d362093f9e Introduce GIT_MERGE_CONFIG_* for merge.ff settings
git_merge_analysis will now return GIT_MERGE_CONFIG_NO_FASTFORWARD
when merge.ff=false and GIT_MERGE_CONFIG_FASTFORWARD_ONLY when
merge.ff=true
2014-05-27 20:49:16 -05:00
Cha, Hojeong
3ac1ff42d7 Fix compile error on Visual Studio 2014-05-27 23:36:07 +09:00
Carlos Martín Nieto
433ba614a2 Merge pull request #2382 from mikeando/doc_fixes
Fixed miscellaneous documentation errors.
2014-05-26 08:38:39 +02:00
Edward Lee
517341c5d8 Address style concerns in setting mkdir/copy flags. 2014-05-23 22:41:35 -04:00
Eoin Coffey
87493bca9c Remove simple --author, --committer, and --grep from PROJECTS 2014-05-23 13:00:30 -06:00
Eoin Coffey
26cce32133 Add support for --grep 2014-05-23 12:59:19 -06:00
Eoin Coffey
161e6dc1ca Add --committer option, and break out helper function 2014-05-23 12:27:16 -06:00
Michael Anderson
31b0cb518f Fixed miscellaneous documentation errors. 2014-05-23 15:57:20 +08:00
Carlos Martín Nieto
530594c0aa odb: clear backend errors on successful read
We go through the different backends in order, so it's not an error if
at least one of the backends has the data we want.
2014-05-23 06:01:57 +02:00
Eoin Coffey
97fc71ab3b Add support for --author flag in example log implementation 2014-05-22 17:22:45 -06:00
Carlos Martín Nieto
052a2ffde4 index: check for valid filemodes on add 2014-05-22 16:01:02 +02:00
Carlos Martín Nieto
9331f98aca smart: initialize the error variable 2014-05-22 12:52:31 +02:00
Carlos Martín Nieto
4c4408c351 Plug leaks and fix a C99-ism
We have too many places where we repeat free code, so when adding the
new free to the generic code, it didn't take for the local transport.

While there, fix a C99-ism that sneaked through.
2014-05-22 12:28:39 +02:00
Vicent Marti
a598264463 Merge pull request #2376 from libgit2/cmn/remote-symref
Add support for the symref extension
2014-05-22 02:28:42 +02:00
Vicent Marti
7ee233a920 Merge pull request #2375 from libgit2/rb/safecrlf-on-lf-platform
Make core.safecrlf not generate an error on LF-ending platforms
2014-05-22 02:27:33 +02:00
Vicent Marti
ff9fb4484b Merge pull request #2379 from ethomson/status_win32
Include windows.h on win32 for Sleep
2014-05-22 02:26:56 +02:00
Edward Thomson
ead9c591ef Include windows.h on win32 for Sleep 2014-05-21 17:25:00 -07:00
Carlos Martín Nieto
7230330740 travis: build on osx too 2014-05-21 14:43:44 +02:00
Vicent Marti
2bc36facce Merge pull request #2372 from libgit2/cmn/fetch-terminate
smart: send a flush when we disconnect
2014-05-21 13:07:45 +02:00
Carlos Martín Nieto
2a59711658 clone: get rid of head_info
Since we no longer need to push data to callbacks, there's no need for
this truct.
2014-05-21 12:12:33 +02:00
Carlos Martín Nieto
cdb8a60824 clone: make use of the remote's default branch guessing
Let's use the remote's default branch guessing instead of reinventing
one ourselves with callbacks.
2014-05-21 12:12:32 +02:00
Carlos Martín Nieto
d22db24fb7 remote: add api to guess the remote's default branch
If the remote supports the symref protocol extension, then we return
that, otherwise we guess with git's rules.
2014-05-21 12:12:32 +02:00
Carlos Martín Nieto
04865aa05e local transport: expose the symref data
When using the local transport, we always have the symbolic information
available, so fill it.
2014-05-21 12:12:32 +02:00