|
511b2370
|
2011-04-04T17:24:37
|
|
tests: update NAMING file
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
b153589b
|
2011-04-03T18:31:45
|
|
Make reinitializing a repository return GIT_ENOTIMPLEMENTED instead of GIT_SUCCESS
|
|
f3564e1e
|
2011-04-03T13:50:09
|
|
Fix tag reference name in testrepo.git
The git test repository was holding a wrongly named tag reference ("very-simple") pointing at a tag named "e90810b".
This mistake (mine :-/ ) originates back to https://github.com/libgit2/libgit2/commit/9282e92
Whole credit goes to @tclem for having spotted this.
|
|
d69d0185
|
2011-04-04T13:05:20
|
|
Add a fake wstream to the ODB
Streaming writes will no longer fail when writing to a backend that
doesn't support streaming writes but supports direct ones.
Now we create a fake stream on memory and then write it as a single
block using the backend `write` callback.
|
|
29e1789b
|
2011-04-04T12:14:03
|
|
Fix the git_tree_write implementation
|
|
47d8ec56
|
2011-04-03T17:18:56
|
|
New external API method: `git_tree_create`
Creates a tree by scanning the index file. The method handles recursive
creation of trees for subdirectories and adds them to the parent tree.
|
|
3e3e4631
|
2011-04-02T12:49:14
|
|
Merge branch 'tagging' of https://github.com/nulltoken/libgit2 into development
Conflicts:
include/git2/tag.h
src/tag.c
|
|
720d5472
|
2011-04-02T12:42:04
|
|
Change `parse` methods to const buffer
Signed-off-by: Vicent Marti <tanoku@gmail.com>
|
|
d8ad64d3
|
2011-04-02T12:28:35
|
|
Merge branch 'parse-tag-buffer' of https://github.com/carlosmn/libgit2 into development
|
|
ccfce5f3
|
2011-03-30T19:47:12
|
|
Update README after sqlite option change
To build libgit2 with sqlite support, waf configure should be run
with --with-sqlite
|
|
ba84cad3
|
2011-03-31T15:02:23
|
|
wscript: Use -O0 on debug
If we want debugging symbols, we most likely want them to point to the
right place. With -O2, gdb or valgrind may give wrong information.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
ac26e245
|
2011-03-30T23:46:54
|
|
Rename git_tag_create_o_f() to git_tag_create_fo()
|
|
9e680bcc
|
2011-03-30T23:26:36
|
|
Add git_tag_delete()
|
|
a50c1458
|
2011-03-30T23:16:30
|
|
Add git_tag_create_o_f() and git_tag_create_f() which overwrite existing tag reference, if any
|
|
74e50a2d
|
2011-03-30T22:46:52
|
|
Fix memory leak in tag releated tests
|
|
bf4c39f9
|
2011-03-30T22:30:55
|
|
Prevent tag_create() from creating a conflicting reference
|
|
6d316014
|
2011-03-30T21:57:20
|
|
Add test demonstrating that one can create a tag pointing at a non existent target
|
|
8e9a3d42
|
2011-03-30T21:46:19
|
|
Enforce the testing of the correct creation of a tag
|
|
673de2cf
|
2011-03-30T21:29:10
|
|
Fix misleading comments
|
|
2b9b99b6
|
2011-03-29T21:29:30
|
|
Add test ensuring one can not create an oid reference which targets at an unknown id
|
|
4d00dfd4
|
2011-03-29T21:21:47
|
|
Replace gitfo_unlink() calls with git_reference_delete() in refs related tests
|
|
a796d24c
|
2011-03-29T14:19:40
|
|
Fix help message for waf configure --with-sqlite
|
|
553fbd64
|
2011-03-29T11:43:31
|
|
Check for looser reference names
res/dummy/a and refs/stash must pass. The other rules are already
tested by the rest of the checks.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
83c95128
|
2011-03-24T14:15:00
|
|
normalize_name: allow more references under refs/
Allow any well-formed reference name to live under refs/ removing the
condition that they be under refs/{heads,tags,remotes}/ as was the
design of git.
An exception is made for HEAD which is allowed to contain an OID
reference in detached HEAD state.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
9a53df7e
|
2011-03-29T19:40:02
|
|
refs: Don't allow references to inexistent OIDs
|
|
95cde17c
|
2011-03-29T19:22:21
|
|
Enforce coding conventions in refs.c
Internal methods are static and without the git prefix.
'Force' methods have a `_f` prefix to match the other 'force' methods.
|
|
fc1eeb9d
|
2011-03-29T11:30:09
|
|
Make overwrite test more comprehensive
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
ec991936
|
2011-03-29T10:52:29
|
|
force-rename test: check for the right name
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
dad4a4d5
|
2011-03-29T10:47:48
|
|
rename: don't return early if the target ref exists
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
c7db45e8
|
2011-03-28T14:53:52
|
|
Match the comment with the error string
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
fa204962
|
2011-03-28T12:00:50
|
|
Allow forcing the creation or renaming of references
Add internal reference create and rename functions which take a force
parameter, telling them to overwrite an existing reference if it
exists.
These functions try to update the reference if it's of the same type
as the one it's going to be replaced by. Otherwise the old reference
becomes invalid.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
baad182c
|
2011-03-28T11:31:58
|
|
Add GIT_EEXISTS error code
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
591a9423
|
2011-03-28T18:40:58
|
|
Add tests covering overwriting references
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
4cd6ed75
|
2011-03-28T15:05:02
|
|
Fix documentation copy error
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
6dcb09b5
|
2011-03-28T22:35:27
|
|
libgit2 version 0.11.0, "McSwifty"
Apologies for the massive changes in the external API (that's my fault),
and for the terrible codename for this release (that's @tclem's fault).
The detailed overview for the major API changes can be found in the
commit at 72a3fe42fb7208712bbe8f0981f4c6274c05e9c3.
Major new features in this release:
- Real caching and refcounting on parsed objects
- Real caching and refcounting on objects read from the ODB
- Streaming writes & reads from the ODB
- Single-method writes for all object types
- The external API is now partially thread-safe
- Improved reference handling
- New method to list references
- ZLib is now built-in
- Improvements to the Revision Walker
- Tons of bug fixes
Thanks to all the contributors who make this possible.
Signed-off-by: Vicent Marti <tanoku@gmail.com>
|
|
483526eb
|
2011-03-28T22:23:44
|
|
Update the SQLite backend
|
|
683581a3
|
2011-03-28T17:59:13
|
|
index.c: Fix tiny typos
|
|
9d80d74d
|
2011-03-28T17:57:08
|
|
signature.h: Fix tiny typo
|
|
7b4a16e2
|
2011-03-28T13:59:48
|
|
Add git_tag_create_frombuffer API
Expose the tag parsing capabilities already present in the
library.
Exporting this function makes it possible to implement the
mktag command without duplicating this functionality.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
c15e0db5
|
2011-03-28T13:58:44
|
|
Fix memory leak in parse_tag_buffer
Free the allocated memory if the signature parsing reports an error.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
09e8de0f
|
2011-03-25T23:53:38
|
|
New external API method: `git_reference_listcb`
List all the references in the repository, calling a custom
callback for each one.
The listed references may be filtered by type, or using
a bitwise OR of several types. Use the magic value
`GIT_REF_LISTALL` to obtain all references, including
packed ones.
The `callback` function will be called for each of the references
in the repository, and will receive the name of the reference and
the `payload` value passed to this method.
|
|
051d6915
|
2011-03-24T18:28:04
|
|
index.h: Fix minor typo
|
|
12f6d8e1
|
2011-03-24T13:48:22
|
|
index.h: Correct documentation for git_index_open_inrepo()
Fix the doxygen comments for git_index_open_inrepo(). Previously they
referred to a param index_path and omitted index (probably a c&p
error).
|
|
3bdc0d4c
|
2011-03-24T15:32:24
|
|
index.c: Read index after initialization
The current behaviour of git_index_open{bare,inrepo}() is unexpected.
When an index is opened, an in-memory index object is created that is
linked to the index discovered by git_repository_open(). However, this
index object is empty, as the on-disk index is not read. To fully open
the on-disk index file, git_index_read() has to be called. This leads to
confusing behaviour. Consider the following code:
git_index *idx;
git_index_open_inrepo(&idx, repo);
git_index_write(idx);
You would expect this to have no effect, as the index is never
ostensibly manipulated. However, what actually happens is that the index
entries are removed from the on-disk index because the empty in-memory
index object created by open_inrepo() is written back to the disk.
This patch reads the index after opening it.
|
|
f3cf7f6d
|
2011-03-23T17:06:49
|
|
add go-git (Go bindings) to the readme
|
|
815c9bc7
|
2011-03-23T20:18:34
|
|
Remove circular dependency in includes
|
|
ea269511
|
2011-03-23T14:57:41
|
|
odb.h: Fix minor typo
Fix a doxygen typo ("@para" instead of "@param") in odb.h
|
|
c585f55f
|
2011-03-23T12:35:08
|
|
common.h: Fix minor typos
Fix a few minor typos in the documentation of the GIT_ERROR codes.
|
|
f6f72d7e
|
2011-03-23T18:44:53
|
|
Improve the ODB writing backend
Temporary files when doing streaming writes are now stored inside the
Objects folder, to prevent issues when moving files between
disks/partitions.
Add support for block writes to the ODB again (for those backends that
cannot implement streaming).
|
|
08db1efd
|
2011-03-23T15:53:12
|
|
Add Ocaml bindings to the readme
|
|
c0ffe518
|
2011-03-23T15:44:52
|
|
Do not return on `void` helper methods
MSVC doesn't swallow that.
|
|
f0d08b7c
|
2011-03-23T15:40:47
|
|
Remove `git_repository_gc` from the headers
|
|
b0b83135
|
2011-03-22T16:15:50
|
|
Add close wappers for commit, tree, tag and blob
In the same spirit that git_repository_lookup is no longer available,
add wrappers so the users don't have to cast when closing their
objects.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
7c80c19e
|
2011-03-23T01:58:18
|
|
Fix compilation in MinGW
|
|
a8375f53
|
2011-03-05T15:09:01
|
|
Add test exercising the opening of an standard repository initialized by git
|
|
2ce44b67
|
2011-03-05T14:33:31
|
|
Add test exercising the opening of an empty bare repository initialized by git
|
|
29e1797c
|
2011-03-05T14:26:22
|
|
Add remove_placeholders() test helper function which recursively removes marker files from a directory structure
|
|
3fe9c60c
|
2011-03-23T00:21:30
|
|
Add empty bare and normal repos to test resources
We have removed the hooks folder because it takes a lot of space
|
|
2b861d75
|
2011-03-19T08:31:40
|
|
Add detection of incorrect usage to git__joinpath()
|
|
f428ae61
|
2011-03-19T08:19:34
|
|
Slightly enforce copy_recurs() behavior
The folder creation is now decorrelated from the recursive parsing of the source tree structure.
|
|
ba1bdf86
|
2011-03-18T22:27:15
|
|
Improve test coverage of new path prettifying behavior
|
|
3644e98f
|
2011-03-18T19:10:36
|
|
Fix detection of attempt to escape the root directory on Windows
|
|
6279abda
|
2011-03-17T06:56:58
|
|
Make gitfo_prettify_dir_path() and gitfo_prettify_file_path() no longer externalized
|
|
677a3c07
|
2011-03-15T22:07:01
|
|
Add failing test for issue 84
see https://github.com/libgit2/libgit2/issues#issue/84
|
|
c90292ce
|
2011-03-18T16:56:43
|
|
Change gitfo_prettify_dir_path() and gitfo_prettify_file_path() behavior
Those functions now return prettified rooted path.
|
|
ae6ba7f7
|
2011-03-22T19:45:01
|
|
Fix gitfo_mv() behavior when running on Windows
When the system temporary folder is located on a different volume than the working directory into which libgit2 is executing, MoveFileEx() requires an additional flag.
|
|
56d8ca26
|
2011-03-20T18:36:25
|
|
Switch from time_t to git_time_t
git_time_t is defined as a signed 64 integer. This allows a true predictable multiplatform behavior.
|
|
fe192020
|
2011-03-21T23:27:54
|
|
Corrected the header include directory in doxygen conf
|
|
21d73e71
|
2011-03-22T20:26:01
|
|
Always free the parents of a revwalk commit
Thanks to Carlos Martín Nieto for spotting this.
|
|
1881f078
|
2011-03-21T20:28:02
|
|
Add getters for `git_odb_object`
|
|
b932ef5b
|
2011-03-21T19:44:43
|
|
Fix MSVC warnings when building threads
|
|
567fc1d2
|
2011-03-22T12:47:53
|
|
refs loose_lookup: also free the buffer on success
Free the ref_file buffer at the end of the function also on
success. This fixes a small memory leak.
|
|
70236bab
|
2011-03-21T19:39:06
|
|
Update CMakeLists.txt to support threadsafe
|
|
99baacfb
|
2011-03-21T19:27:45
|
|
Fix MSVC warnings
|
|
72a3fe42
|
2011-03-18T19:38:49
|
|
I broke your bindings
Hey. Apologies in advance -- I broke your bindings.
This is a major commit that includes a long-overdue redesign of the
whole object-database structure. This is expected to be the last major
external API redesign of the library until the first non-alpha release.
Please get your bindings up to date with these changes. They will be
included in the next minor release. Sorry again!
Major features include:
- Real caching and refcounting on parsed objects
- Real caching and refcounting on objects read from the ODB
- Streaming writes & reads from the ODB
- Single-method writes for all object types
- The external API is now partially thread-safe
The speed increases are significant in all aspects, specially when
reading an object several times from the ODB (revwalking) and when
writing big objects to the ODB.
Here's a full changelog for the external API:
blob.h
------
- Remove `git_blob_new`
- Remove `git_blob_set_rawcontent`
- Remove `git_blob_set_rawcontent_fromfile`
- Rename `git_blob_writefile` -> `git_blob_create_fromfile`
- Change `git_blob_create_fromfile`:
The `path` argument is now relative to the repository's working dir
- Add `git_blob_create_frombuffer`
commit.h
--------
- Remove `git_commit_new`
- Remove `git_commit_add_parent`
- Remove `git_commit_set_message`
- Remove `git_commit_set_committer`
- Remove `git_commit_set_author`
- Remove `git_commit_set_tree`
- Add `git_commit_create`
- Add `git_commit_create_v`
- Add `git_commit_create_o`
- Add `git_commit_create_ov`
tag.h
-----
- Remove `git_tag_new`
- Remove `git_tag_set_target`
- Remove `git_tag_set_name`
- Remove `git_tag_set_tagger`
- Remove `git_tag_set_message`
- Add `git_tag_create`
- Add `git_tag_create_o`
tree.h
------
- Change `git_tree_entry_2object`:
New signature is `(git_object **object_out, git_repository *repo, git_tree_entry *entry)`
- Remove `git_tree_new`
- Remove `git_tree_add_entry`
- Remove `git_tree_remove_entry_byindex`
- Remove `git_tree_remove_entry_byname`
- Remove `git_tree_clearentries`
- Remove `git_tree_entry_set_id`
- Remove `git_tree_entry_set_name`
- Remove `git_tree_entry_set_attributes`
object.h
------------
- Remove `git_object_new
- Remove `git_object_write`
- Change `git_object_close`:
This method is now *mandatory*. Not closing an object causes a
memory leak.
odb.h
-----
- Remove type `git_rawobj`
- Remove `git_rawobj_close`
- Rename `git_rawobj_hash` -> `git_odb_hash`
- Change `git_odb_hash`:
New signature is `(git_oid *id, const void *data, size_t len, git_otype type)`
- Add type `git_odb_object`
- Add `git_odb_object_close`
- Change `git_odb_read`:
New signature is `(git_odb_object **out, git_odb *db, const git_oid *id)`
- Change `git_odb_read_header`:
New signature is `(size_t *len_p, git_otype *type_p, git_odb *db, const git_oid *id)`
- Remove `git_odb_write`
- Add `git_odb_open_wstream`
- Add `git_odb_open_rstream`
odb_backend.h
-------------
- Change type `git_odb_backend`:
New internal signatures are as follows
int (* read)(void **, size_t *, git_otype *, struct git_odb_backend *, const git_oid *)
int (* read_header)(size_t *, git_otype *, struct git_odb_backend *, const git_oid *)
int (* writestream)(struct git_odb_stream **, struct git_odb_backend *, size_t, git_otype)
int (* readstream)( struct git_odb_stream **, struct git_odb_backend *, const git_oid *)
- Add type `git_odb_stream`
- Add enum `git_odb_streammode`
Signed-off-by: Vicent Marti <tanoku@gmail.com>
|
|
bb3de0c4
|
2011-03-16T21:35:51
|
|
Thread safe cache
|
|
b5c5f0f8
|
2011-03-16T23:59:09
|
|
Fix headers for the new Revision Walker
The "oid.h" header is now included instead of "object.h".
The old "revwalk.h" header has been removed; it was empty.
|
|
7341bf87
|
2011-03-16T23:13:28
|
|
Refs are now always in-sync on disk
|
|
9f81a37a
|
2011-03-16T23:02:31
|
|
Define NO_GZIP in zconf.h instead of at compile time
|
|
36aaf1ff
|
2011-03-16T01:53:25
|
|
Change the Revwalk reset behavior to the old version
The `reset` call now removes the pushed commits so we can reuse
the revwalker. The API documentation has been updated with the details.
|
|
8613d4a9
|
2011-03-16T01:10:40
|
|
Fix signature in `git_repository_gc`
The method returns an int with the amount of objects free'd
|
|
54a1b36c
|
2011-03-16T01:07:06
|
|
Export `git_repository_gc` properly
One of my brainfarts made me export it as `git_repository_close` instead
of GC. Duh.
|
|
955f9ae9
|
2011-03-16T01:06:15
|
|
Export `git_strarray_free` instead of inlining
That way non-C bindings can use it.
|
|
36b31329
|
2011-03-16T01:04:17
|
|
Properly free commit a commit list in revwalk
The commit list was not being properly free'd when a walk was stopped
halfway through.
|
|
f73b09cd
|
2011-03-15T21:19:02
|
|
Revert changes in wscript file
|
|
bbcc7ffc
|
2011-03-15T21:04:41
|
|
Add proper threading support to libgit2
We now depend on libpthread on all Unix platforms (should be installed
by default) and use a simple wrapper for Windows threads under Win32.
Signed-off-by: Vicent Marti <tanoku@gmail.com>
|
|
b5abb881
|
2011-03-15T19:55:01
|
|
Do not segfault when listing unpacked references
|
|
d40d30cb
|
2011-03-15T19:54:45
|
|
Debug assertion when using an initialized hashtable
|
|
434bedcd
|
2011-03-15T19:46:38
|
|
Fix compilation warnings in ZLib (MSVC)
Yes, we are changing the Zlib code. This is dangerous and uncool.
Fortunately, these are just some implicit casts.
|
|
7ad96e51
|
2011-03-15T05:38:50
|
|
Remove duplicate refs in `git_reference_listall`
|
|
5f8078d4
|
2011-03-15T04:03:54
|
|
Use a more sane zconf.f when building Zlib
|
|
11a203e1
|
2011-03-15T03:31:52
|
|
Add nodegit to the README
|
|
ab6a3d3d
|
2011-03-15T03:25:44
|
|
Add ZLib as a built-in dependency
I don't know if this is good or bad. This lets libgit2 compile cleanly
on any platforms without any external dependencies, but adds a little
bit of bloat...
Let's test this out and see what happens.
|
|
1ee32c6d
|
2011-03-14T00:33:45
|
|
Add test case for issue GH-86
|
|
bd1aa741
|
2011-03-14T00:07:37
|
|
git_object_lookup() should also check the type if the object comes from the cache
|
|
7c8a7b91
|
2011-03-15T02:45:49
|
|
Skip the optional header in packed-refs files
|
|
7064938b
|
2011-03-14T23:55:32
|
|
libgit2 version 0.10.0, "very disco"
A version *so* awesome that needs 2 version bumps AND a codename.
Major features:
- New internal garbage collection (harder)
- Pack backend rewritten from scratch (better)
- Revision walker rewritten from scratch (faster)
- New object interdependency system (stronger)
- Unique OID shortener
- Reference listing
In honor of one heck of a music album, released ten years ago,
yesterday.
|
|
6b2a1941
|
2011-03-12T23:09:16
|
|
Fix the retarded object interdependency system
It's no longer retarded. All object interdependencies are stored as OIDs
instead of actual objects. This should be hundreds of times faster,
specially on big repositories. Heck, who knows, maye it doesn't even
segfault -- wouldn't that be awesome?
What has changed on the API?
`git_commit_parent`, `git_commit_tree`, `git_tag_target` now return
their values through a pointer-to-pointer, and have an error code.
`git_commit_set_tree` and `git_tag_set_target` now return an error
code and may fail.
`git_repository_free__no_gc` has been deprecated because it's
stupid. Since there are no longer any interdependencies between
objects, we don't need internal reference counting, and GC
never fails or double-free's pointers.
`git_object_close` now does a very sane thing: marks an object
as unused. Closed objects will be eventually free'd from the
object cache based on LRU. Please use `git_object_close` from
the garbage collector `destroy` method on your bindings. It's
100% safe.
`git_repository_gc` is a new method that forces a garbage collector
pass through the repo, to free as many LRU objects as possible.
This is useful if we are running out of memory.
|
|
00571828
|
2011-03-12T16:04:46
|
|
Add new method `git_reference_listall`
Lists all the references in a repository. Listing may be filtered by
reference type.
This should applease Lord Clem.
|
|
58d06cf1
|
2011-03-10T01:06:24
|
|
Rewrite the Pack backend
The new pack backend is an adaptation of the original git.git code in
`sha1_file.c`. It's slightly faster than the previous version and
severely less memory-hungry.
The call-stack of a normal pack backend query has been properly
documented in the top of the header for future reference. And by
properly I mean with ASCII diagrams 'n shit.
|