|
d00d5464
|
2013-03-01T15:37:33
|
|
immutable references and a pluggable ref database
|
|
bb45c57f
|
2013-03-07T16:38:44
|
|
refs: explicitly catch leading slashes
It's somewhat common to try to write "/refs/tags/something". There is
no easy way to catch it during the main body of the function, as there
is no way to distinguish whether it's a leading slash or a double
slash somewhere in the middle.
Catch this at the beginning so we don't trigger the assert in
is_all_caps_and_underscore().
|
|
9952f24e
|
2013-03-06T16:02:26
|
|
No longer need clar_main.c
|
|
aa518c70
|
2013-03-06T22:51:20
|
|
added missing free for git_note in clar tests
|
|
f7b18502
|
2013-03-06T22:25:01
|
|
fixed minor issues with new note iterator
* fixed style issues
* use new iterator functions for git_note_foreach()
|
|
1a90dcf6
|
2013-03-06T19:07:56
|
|
use git_note_iterator type instead of non-public git_iterator one
|
|
6edb427b
|
2013-03-06T16:43:21
|
|
basic note iterator implementation
* git_note_iterator_new() - create a new note iterator
* git_note_next() - retrieves the next item of the iterator
|
|
4cc326e9
|
2013-03-05T22:45:26
|
|
remote push test fix
|
|
b72f5d40
|
2013-03-05T15:35:28
|
|
Merge pull request #1369 from arrbee/repo-init-template-hooks
More tests (and fixes) for initializing repo from template
|
|
5bddabcc
|
2013-03-04T17:40:48
|
|
clear REUC on checkout
|
|
323bb885
|
2013-03-04T00:21:56
|
|
Fix a few leaks
`git_diff_get_patch()` would unconditionally load the patch object and
then simply leak it if the user hadn't requested it. Short-circuit
loading the object if the user doesn't want it.
The rest of the plugs are simply calling the free functions of objects
allocated during the tests.
|
|
447ae791
|
2013-03-03T15:19:21
|
|
indexer: kill git_indexer
This was the first implementation and its goal was simply to have
something that worked. It is slow and now it's just taking up
space. Remove it and switch the one known usage to use the streaming
indexer.
|
|
487fc724
|
2013-03-01T13:41:53
|
|
Allow empty config object and use it
This removes assertions that prevent us from having an empty
git_config object and then updates some tests that were
dependent on global config state to use an empty config before
running anything.
|
|
47f70846
|
2013-03-01T13:27:46
|
|
Merge pull request #1379 from arrbee/fix-tests-with-autocrlf-input-on-windows
Control for core.autocrlf during testing
|
|
7d46b34b
|
2013-03-01T12:26:05
|
|
Control for core.autocrlf during testing
|
|
926acbcf
|
2013-03-01T11:07:53
|
|
Clone should not delete directories it did not create
|
|
e68e33f3
|
2013-02-27T14:50:32
|
|
Merge pull request #1233 from arrbee/file-similarity-metric
Add file similarity scoring to diff rename/copy detection
|
|
18f08264
|
2013-02-27T13:44:15
|
|
Make mode handling during init more like git
When creating files, instead of actually using GIT_FILEMODE_BLOB
and the other various constants that happen to correspond to
mode values, apparently I should be just using 0666 and 0777, and
relying on the umask to clear bits and make the value sane.
This fixes the rules for copying a template directory and fixes
the checks to match that new behavior. (Further changes to the
checkout logic to follow separately.)
|
|
395509ff
|
2013-02-27T14:47:39
|
|
don't dereference at the end of the workdir iterator
|
|
0d1b094b
|
2013-02-26T13:15:06
|
|
Fix portability issues on Windows
The new tests were not taking core.filemode into account when
testing file modes after repo initialization. Fixed that and some
other Windows warnings that have crept in.
|
|
3c42e4ef
|
2013-02-26T11:43:14
|
|
Fix initialization of repo directories
When PR #1359 removed the hooks from the test resources/template
directory, it made me realize that the tests for
git_repository_init_ext using templates must be pretty shabby
because we could not have been testing if the hooks were getting
created correctly.
So, this started with me recreating a couple of hooks, including
a sample and symlink, and adding tests that they got created
correctly in the various circumstances, including with the SHARED
modes, etc. Unfortunately this uncovered some issues with how
directories and symlinks were copied and chmod'ed. Also, there
was a FIXME in the code related to the chmod behavior as well.
Going back over the directory creation logic for setting up a
repository, I found it was a little difficult to read and could
result in creating and/or chmod'ing directories that the user
almost certainly didn't intend.
So that let to this work which makes repo initialization much
more careful (and hopefully easier to follow). It required a
couple of extensions / changes to core fileops utilities, but I
also think those are for the better, at least for git_futils_cp_r
in terms of being careful about what actions it takes.
|
|
8005c6d4
|
2013-02-26T01:03:56
|
|
Revert "hash: remove git_hash_init from internal api"
This reverts commit efe7fad6c96a3d6197a218aeaa561ec676794499, except for
the indentation fixes.
|
|
efe7fad6
|
2013-02-26T00:05:28
|
|
hash: remove git_hash_init from internal api
Along with that, fix indentation in tests-clar/object/raw/hash.c
|
|
be225be7
|
2013-02-25T23:36:25
|
|
tests/pack: fixup 6774b10
Initialize the hash ctx with git_hash_ctx_init, not git_hash_init.
|
|
6774b107
|
2013-02-17T17:52:16
|
|
tests/pack: do strict check of testpack's SHA1 hash
|
|
fc6c5b50
|
2013-02-25T17:03:05
|
|
Remove sample hook files
Getting rid of sample hook files from test repos as they just take up
space with no value.
|
|
37d91686
|
2013-02-22T12:21:54
|
|
Do not fail if .gitignore is directory
This is designed to fix libgit2sharp #350 where if .gitignore is
a directory we abort all operations that process ignores instead
of just skipping it as core git does.
Also added test that fails without this change and passes with it.
|
|
1be4ba98
|
2013-02-22T11:13:01
|
|
More rename detection tests
This includes tests for crlf changes, whitespace changes with the
default comparison and with the ignore whitespace comparison, and
more sensitivity checking for the comparison code.
|
|
7beeb3f4
|
2013-02-22T14:03:44
|
|
Rename 'exp' so it doesn't conflict with exp()
|
|
6f9d5ce8
|
2013-02-22T10:17:08
|
|
Fix tests for find_similar and related
This fixes both a test that I broke in diff::patch where I was
relying on the current state of the working directory for the
renames test data and fixes an unstable test in diff::rename
where the environment setting for the "diff.renames" config was
being allowed to influence the test results.
|
|
06eaa06f
|
2013-02-22T09:48:47
|
|
Merge pull request #1343 from nulltoken/topic/remote_orphaned_branch
Teach git_branch_remote_name() to work with orphaned heads
|
|
bbc53e4f
|
2013-02-15T12:43:03
|
|
branch: refactor git_branch_remote_name() tests
|
|
c1b5e8c4
|
2013-02-15T11:35:33
|
|
branch: Make git_branch_remote_name() cope with orphaned heads
|
|
9ccab8df
|
2013-02-22T15:25:06
|
|
stash: Update the reference when dropping the topmost stash
|
|
39bcb4de
|
2013-02-22T14:44:57
|
|
stash: Refactor stash::drop tests
|
|
d788499a
|
2013-02-22T15:02:37
|
|
ignore: enhance git_ignore_path_is_ignored() test coverage
|
|
d4b747c1
|
2013-02-21T16:44:44
|
|
Add diff rename tests with partial similarity
This adds some new tests that actually exercise the similarity
metric between files to detect renames, copies, and split modified
files that are too heavily modified.
There is still more testing to do - these tests are just partially
covering the cases.
There is also one bug fix in this where a change set with only
MODIFY being broken into ADD/DELETE (due to low self-similarity)
without any additional RENAMED entries would end up not processing
the split requests (because the num_rewrites counter got reset).
|
|
960a04dd
|
2013-02-21T12:40:33
|
|
Initial integration of similarity metric to diff
This is the initial integration of the similarity metric into
the `git_diff_find_similar()` code path. The existing tests all
pass, but the new functionality isn't currently well tested. The
integration does go through the pluggable metric interface, so it
should be possible to drop in an alternative to the internal
metric that libgit2 implements.
This comes along with a behavior change for an existing interface;
namely, passing two NULLs to git_diff_blobs (or passing NULLs to
git_diff_blob_to_buffer) will now call the file_cb parameter zero
times instead of one time. I know it's strange that that change
is paired with this other change, but it emerged from some
initialization changes that I ended up making.
|
|
71a3d27e
|
2013-02-08T10:06:47
|
|
Replace diff delta binary with flags
Previously the git_diff_delta recorded if the delta was binary.
This replaces that (with no net change in structure size) with
a full set of flags. The flag values that were already in use
for individual git_diff_file objects are reused for the delta
flags, too (along with renaming those flags to make it clear that
they are used more generally).
This (a) makes things somewhat more consistent (because I was
using a -1 value in the "boolean" binary field to indicate unset,
whereas now I can just use the flags that are easier to understand),
and (b) will make it easier for me to add some additional flags to
the delta object in the future, such as marking the results of a
copy/rename detection or other deltas that might want a special
indicator.
While making this change, I officially moved some of the flags that
were internal only into the private diff header.
This also allowed me to remove a gross hack in rename/copy detect
code where I was overwriting the status field with an internal
value.
|
|
9bc8be3d
|
2013-02-19T10:25:41
|
|
Refine pluggable similarity API
This plugs in the three basic similarity strategies for handling
whitespace via internal use of the pluggable API. In so doing, I
realized that the use of git_buf in the hashsig API was not needed
and actually just made it harder to use, so I tweaked that API as
well.
Note that the similarity metric is still not hooked up in the
find_similarity code - this is just setting out the function that
will be used.
|
|
aa643260
|
2013-02-15T11:08:02
|
|
More tests of file signatures with whitespace opts
Seems to be working pretty well...
|
|
5e5848eb
|
2013-02-14T17:25:10
|
|
Change similarity metric to sampled hashes
This moves the similarity metric code out of buf_text and into a
new file. Also, this implements a different approach to similarity
measurement based on a Rabin-Karp rolling hash where we only keep
the top 100 and bottom 100 hashes. In theory, that should be
sufficient samples to given a fairly accurate measurement while
limiting the amount of data we keep for file signatures no matter
how large the file is.
|
|
9c454b00
|
2013-01-11T22:13:02
|
|
Initial implementation of similarity scoring algo
This adds a new `git_buf_text_hashsig` type and functions to
generate these hash signatures and compare them to give a
similarity score. This can be plugged into diff similarity
scoring.
|
|
f2e1d060
|
2013-02-20T12:00:51
|
|
Merge pull request #1351 from arrbee/moar-treebuilder-tests
Add more treebuilder tests
|
|
0cfce06d
|
2013-02-20T11:58:21
|
|
Add more treebuilder tests
The recent changes with git_treebuilder_entrycount point out that
the test coverage for git_treebuilder_remove and
git_treebuilder_entrycount is completely absent. This adds tests.
|
|
f7511c2c
|
2013-02-20T10:19:58
|
|
Merge pull request #1348 from libgit2/signatures-2
Simplify signature parsing
|
|
63964c89
|
2013-02-20T18:49:00
|
|
Disable caching in Clar
|
|
c51880ee
|
2013-02-20T17:03:18
|
|
Simplify signature parsing
|
|
56543a60
|
2013-02-15T16:02:45
|
|
Clear up warnings from cppcheck
The cppcheck static analyzer generates warnings for a bunch of
places in the libgit2 code base. All the ones fixed in this
commit are actually false positives, but I've reorganized the
code to hopefully make it easier for static analysis tools to
correctly understand the structure. I wouldn't do this if I
felt like it was making the code harder to read or worse for
humans, but in this case, these fixes don't seem too bad and will
hopefully make it easier for better analysis tools to get at any
real issues.
|
|
fcd7733d
|
2013-02-14T12:49:46
|
|
Merge pull request #1318 from nulltoken/topic/diff-tree-coverage
Topic/diff tree coverage
|
|
6a0ffe84
|
2013-02-12T10:50:55
|
|
Merge pull request #1333 from phkelley/push_options
Add git_push_options, to set packbuilder parallelism
|
|
fbe67de9
|
2013-02-12T10:16:30
|
|
Merge pull request #1246 from arrbee/fix-force-text-for-diff-blobs
Add FORCE_TEXT check into git_diff_blobs code path
|
|
9c258af0
|
2013-02-12T10:13:56
|
|
Merge pull request #1316 from ben/clone-cancel
Allow network operations to cancel
|
|
c2c0874d
|
2013-02-11T14:44:56
|
|
More diff tests with binary data
|
|
2bca5b67
|
2013-02-07T23:44:18
|
|
remote: Introduce git_remote_is_valid_name()
Fix libgit2/libgit2sharp#318
|
|
4d811c3b
|
2013-02-07T23:40:10
|
|
refs: No component of a refname can end with '.lock'
|
|
624924e8
|
2013-02-07T23:02:56
|
|
remote: reorganize tests
|
|
390a3c81
|
2013-02-11T11:44:00
|
|
Merge pull request #1190 from nulltoken/topic/reset-paths
reset: Allow the selective reset of pathspecs
|
|
e026cfee
|
2013-02-11T09:12:39
|
|
Merge pull request #1323 from jamill/resolve_remote
Resolve a remote branch's remote
|
|
db4bb415
|
2013-02-07T14:53:52
|
|
Teach refspec to transform destination reference to source reference
|
|
2e3e8c88
|
2013-02-08T11:05:47
|
|
Teach remote branch to return its remote
|
|
b8b897bb
|
2013-02-11T08:28:53
|
|
Add git_push_options, to set packbuilder parallelism
|
|
8c29dca6
|
2013-02-11T09:25:57
|
|
Fix some incorrect MSVC #ifdef's. Fixes #1305
|
|
6ce61a0b
|
2013-02-08T14:25:41
|
|
tests: fix whitespace in refs/rename.c
|
|
0d64ba48
|
2013-01-25T17:35:46
|
|
diff: add a notify callback to `git_diff__from_iterators`
The callback will be called for each file, just before the `git_delta_t` gets inserted into the diff list.
When the callback:
- returns < 0, the diff process will be aborted
- returns > 0, the delta will not be inserted into the diff list, but the diff process continues
- returns 0, the delta is inserted into the diff list, and the diff process continues
|
|
c9459abb
|
2013-02-07T03:12:39
|
|
tests: fix indentation in repo/message.c
|
|
f7b06018
|
2013-02-07T03:04:50
|
|
tests: fix indentation in repo/init.c
|
|
1ca163ff
|
2013-02-07T02:04:17
|
|
tests: fix code style in threads/basic.c
|
|
beede432
|
2013-02-06T13:25:43
|
|
Fetchhead: don't expect a tag that isn't there
|
|
169fa384
|
2013-02-06T13:16:13
|
|
Fix fetchhead tests to expect nearly-dangling
|
|
e8993455
|
2012-08-15T20:08:09
|
|
diff: Enhance tree-to-tree diff test coverage
These tests are related to issue libgit2/libgit2sharp#196
|
|
7e858045
|
2013-02-06T16:06:17
|
|
diff: refactor git_diff_tree_to_tree() tests
|
|
f093cd62
|
2012-08-15T18:49:01
|
|
Add unsymlinked.git test repository
|
|
def60ea4
|
2013-02-05T13:14:48
|
|
Allow all non-zero returns to cancel transfers
|
|
42385c96
|
2013-02-05T12:10:08
|
|
Enhance test coverage for transfer cancellation
|
|
3ad05221
|
2013-02-05T16:52:56
|
|
Fix MSVC compilation warnings
Fix #1308
|
|
d96aa8a9
|
2013-01-20T18:24:54
|
|
tests: Remove useless code
|
|
a0c34c94
|
2013-01-20T13:27:28
|
|
reset: Introduce git_reset_default()
|
|
fe95ac1b
|
2013-02-05T10:59:58
|
|
Allow progress callback to cancel fetch
This works by having the indexer watch the return
code of the callback, so will only take effect
on object boundaries.
|
|
de81aee3
|
2013-02-04T14:49:28
|
|
Merge pull request #1298 from ben/user-at
Handle "user@" prefix for credentials partially included in URLs
|
|
0e8e5a61
|
2013-02-03T11:44:26
|
|
revparse: Lookup sha before branch
|
|
545b479a
|
2013-02-02T17:36:20
|
|
revparse: Lookup branch before described tag
Fix #1306
|
|
329eee33
|
2013-02-01T09:41:50
|
|
Merge pull request #1286 from lznuaa/master
Fix clone fail if repo head detached
|
|
aa928de0
|
2013-01-29T17:26:42
|
|
Add test case for clone head detached repo
Signed-off-by: Frank Li <lznuaa@gmail.com>
Signed-off-by: nulltoken <emeric.fermas@gmail.com>
|
|
54ffc1f7
|
2013-01-31T14:41:01
|
|
HTTP: use creds in url if available
|
|
cd74cbba
|
2013-01-31T14:38:22
|
|
Plug test leaks
|
|
cf7038a6
|
2013-01-31T14:04:21
|
|
Enhance url parsing to include passwords
|
|
e5ef0f18
|
2013-01-31T20:23:30
|
|
refs: handle ALLOW_ONELEVEL normalization with leading slash
A leading slash confuses the name normalization code when the flags
include ALLOW_ONELEVEL. Catch this case in particular to avoid
triggering an assertion in the uppercase check which expects us not to
pass it an empty string.
The existing tests don't catch this as they simply use the NORMAL
flag.
This fixes #1300.
|
|
7602cb7c
|
2013-01-31T10:44:57
|
|
Add user-from-url param to auth callback
|
|
5f10853e
|
2013-01-30T18:50:31
|
|
Skip "user@" when finding hostname in url
|
|
3bf68be4
|
2013-01-30T11:25:20
|
|
Free buffer at end of test
|
|
f1e2735c
|
2013-01-30T11:10:39
|
|
Add helper for diff line stats
This adds a `git_diff_patch_line_stats()` API that gets the total
number of adds, deletes, and context lines in a patch. This will
make it a little easier to emulate `git diff --stat` and the like.
Right now, this relies on generating the `git_diff_patch` object,
which is a pretty heavyweight way to get stat information. At
some future point, it would probably be nice to be able to get
this information without allocating the entire `git_diff_patch`,
but that's a much larger project.
|
|
d2041216
|
2013-01-29T13:57:53
|
|
Merge pull request #1296 from arrbee/stricter-config-name-checks
Stricter config entry name validation
|
|
4657fc1c
|
2013-01-29T13:54:08
|
|
Merge pull request #1285 from phkelley/vector
Vector improvements and their fallout
|
|
501d35cc
|
2013-01-29T12:16:59
|
|
Test config name validation
This is @nulltoken's work to test various invalid config section
and key names and make sure we are validating properly.
|
|
17c92bea
|
2013-01-29T12:13:24
|
|
Test buf join with NULL behavior explicitly
|
|
96447d24
|
2013-01-28T16:13:19
|
|
Fix 2 bugs in online::push tests.
- Fix stack corruption introduced in 9bccf33c due to passing pointer to
local variable _cred_acquire_called.
- Fix strcmp in do_verify_push_status when expected or actual push_status
is NULL
|
|
11d9f6b3
|
2013-01-27T14:17:07
|
|
Vector improvements and their fallout
|
|
4adb4815
|
2013-01-25T20:37:39
|
|
Merge pull request #1278 from sba1/cl-assert-equal-s
Use cl_assert_equal_s() instead of strcmp().
|
|
cfc39f50
|
2013-01-25T22:43:52
|
|
Fix 3 memory leaks
|