Commit Graph

1631 Commits

Author SHA1 Message Date
schu
1d33bf9d02 tests-clay: add a readme file
Signed-off-by: schu <schu-github@schulog.org>
2011-10-07 23:13:09 +02:00
schu
681008c768 tests-clay: update clay
The clay script didn't match the latest version from upstream.
Additionaly, add core/strtol.c to complete porting the core tests to
clay.

Signed-off-by: schu <schu-github@schulog.org>
2011-10-07 23:02:02 +02:00
Vicent Marti
3eaf34f4c6 libgit2 v0.15.0 "Das Wunderbar Release"
I am aware the codename is not gramatically correct in any language.

Check the COPYING file for the detailed terms on libgit2's license. Check
the AUTHORS file for the full list of guilty parties.

As we slowly stabilize the API, we've dropped 1 function from the library,
and changed the signature of only 5 of them. There's of course a good
chunk of new functionality, and a thousand bug fixes.

In this release of libgit2:

	- Changed `git_blob_rawsize`: Now returns `size_t` instead of int, allowing
	files >4GB in 64 bit systems.

	- Removed `git_commit_message_short`: Please use `git_commit_message`
	to get the full message and decide which is the "short view" according
	to your needs (first line, first 80 chars...)

	- Added `git_commit_message_encoding`: Returns the encoding field of a commit
	message, if it exists.

	- Changed `git_commit_create`, `git_commit_create_v`: New argument `encoding`, which
	adds a encoding field to the generated commit object.

	- Added `git_config_find_system`: Returns the path to the system's global config
	file (according to the Core Git standards).

	- Changed `git_config_get_XX`, `git_config_set_XX`: the `long` and `int` types have
	been replaced by `int64` and `int32` respectively, to make their meaning more
	obvious.

	- Added `git_indexer`: An interface to index Git Packfiles has been added in the
	`git2/indexer.h` header.

	- Changed `git_reflog_entry_XX`: Reflog entries are now returned as `git_oid *` objects
	instead of hexadecimal OIDs.

	- Added `git_remote`: More fetch functionality has been added to the `git2/remote.h`
	functionality. Local, Smart HTTP and Git protocols are now supported.

	- Added `git_repository_head`: Returns the HEAD of the repository.

	- Added `git_repository_config_autoload`: Opens the configuration file of a repository,
	including the user's and the system's global config files, if they can be found.

	- Changed `git_signature_now`: Now returns an error code; the signature is stored by
	reference.
2011-10-05 16:48:36 -04:00
Vicent Marti
d3fb6a81c3 cmake: Set the old test suite as default for the release 2011-10-05 16:46:34 -04:00
Vicent Marti
dd3fd68266 msvc: Remove superfluous includes 2011-10-05 13:44:27 -07:00
Vicent Marti
c060854ed5 msvc: Properly handle inttypes.h/stdint.h 2011-10-05 16:21:16 -04:00
Carlos Martín Nieto
72d6a20be0 indexer: NUL-terminate the filename
As we no longer use the STRLEN macro, the NUL-terminator in the string
was not copied over. Fix this.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-10-05 20:25:28 +02:00
Vicent Martí
24ce105b40 Merge pull request #441 from csware/ignore-missing-pack-file
ignore missing pack file
2011-10-03 14:42:52 -07:00
Vicent Martí
ef1e5da127 Merge pull request #438 from jdavid/development
Make git_oid_fromstrn support hex strings of odd length
2011-10-03 14:40:06 -07:00
Sven Strickroth
599297fdc3 ignore missing pack file as git does
See http://code.google.com/p/tortoisegit/issues/detail?id=862

Signed-off-by: Sven Strickroth <email@cs-ware.de>
2011-10-03 23:28:24 +02:00
J. David Ibáñez
0e058e789b oid: add missing check to git_oid_fromstrn
Signed-off-by: J. David Ibáñez <jdavid.ibp@gmail.com>
2011-10-02 21:53:04 +02:00
Carlos Martín Nieto
cd19ca9584 Squelch a couple of warnings
Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-10-01 20:16:13 +02:00
Carlos Martín Nieto
9ac581bf7f config: behave like git with [section.subsection]
The documentation is a bit misleading. The subsection name is always
case-sensitive, but with a [section.subsection] header, the subsection
is transformed to lowercase when the configuration is parsed.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-10-01 19:58:26 +02:00
Carlos Martín Nieto
92be7908bd indexer: return immediately if passed a NULL value
Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-10-01 14:46:30 +02:00
Carlos Martín Nieto
922bc22532 pkt: send all of the wants in the negotiation
A missing if caused the function to return after the first want line
without capabilities.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-10-01 14:34:51 +02:00
Carlos Martín Nieto
7ad994bb60 transport-git: fix git request length calculation
There was an off-by-one error that was uncovered when we used the
right length from git_buf.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-10-01 13:46:35 +02:00
Vicent Marti
dfd0abda4d clay: Fix compilation under MSVC 2011-10-01 13:25:24 +02:00
Vicent Marti
10063aeb41 transport-git: Encapsulation ist gut 2011-10-01 13:10:29 +02:00
Vicent Marti
657ce4b5b6 http-transport: Properly cleanup the WSA context 2011-10-01 13:03:19 +02:00
Vicent Marti
1e5b263577 http-transport: Update copyright 2011-10-01 12:58:17 +02:00
Vicent Martí
f77d4f7fc6 Merge pull request #437 from carlosmn/networking-windows
Fix networking on Windows
2011-10-01 03:56:19 -07:00
Carlos Martín Nieto
dc8e3096d6 Include stdint.h in git2/config.h
Otherwise MSVC doesn't know what we're talking about when we say
int32_t or int64_t.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-10-01 02:09:35 +02:00
Carlos Martín Nieto
bad53552e5 netops: abstract away socket closing
Winsock wants us to use closesocket() instead of close(), so introduce
the gitno_close function, which does the right thing.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-10-01 00:41:09 +02:00
Carlos Martín Nieto
a28889198c local transport: don't segfault on wrong URL
memset the structure on initialisation and don't try to dereference
the vector with the heads if we didn't find a repository.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-10-01 00:41:09 +02:00
Carlos Martín Nieto
ccc9872d4d Initialise the winsock DLL
Windows wants us to initialise the networking DLL before we're allowed
to send data through a socket. Call WSASetup and WSACleanup if
GIT_WIN32 is defined.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-10-01 00:41:08 +02:00
Carlos Martín Nieto
a95aeb489f Use git_buf in the git request
This is clearer and sidesteps the issue of what the return value of
snprintf is on the particular OS we're running on.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-10-01 00:41:08 +02:00
Vicent Martí
a70b3c7386 Merge pull request #436 from libgit2/config-int-types
config: Proper type declarations for 64 bit ints
2011-09-30 13:52:01 -07:00
J. David Ibáñez
b9caa1859d oid: now git_oid_fromstrn checks whether the given string is too short
Signed-off-by: J. David Ibáñez <jdavid.ibp@gmail.com>
2011-09-30 19:50:13 +02:00
J. David Ibáñez
6d8d3f195c oid: optimize git_oid_fromstrn by using memset
Signed-off-by: J. David Ibáñez <jdavid.ibp@gmail.com>
2011-09-30 19:41:29 +02:00
J. David Ibáñez
e724b058b2 oid: make git_oid_fromstrn support hex strings of odd length
This fixes issue #433.

Signed-off-by: J. David Ibáñez <jdavid.ibp@gmail.com>
2011-09-30 19:08:48 +02:00
Vicent Marti
107e30e9c5 core: One last long long 2011-09-30 16:25:03 +02:00
Vicent Marti
fafd471021 config: Proper type declarations for 64 bit ints 2011-09-30 16:08:41 +02:00
Carlos Martín Nieto
358a15fd65 config: fix check for environment string expansion
If ExpandEnvironmentStringsW is successful, it returns the amount of
characters written, including the NUL terminator.

Thanks to Emeric for reading the MSDN documentation correctly.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-09-30 15:46:49 +02:00
Vicent Martí
550c9f31bb Merge pull request #434 from schu/fix-ref-regression
refs.c: fix reference_rename
2011-09-30 05:14:04 -07:00
schu
472fa08f4e refs.c: fix reference_rename
6c8b458 removed an "unused" variable needed for git_hashtable_insert2(),
causing a segfault in reference_rename(). Instead, use
git_hashtable_insert().

Signed-off-by: schu <schu-github@schulog.org>
2011-09-30 10:39:33 +02:00
Carlos Martín Nieto
c36280a036 repository: export git_repository_config_autoload
Take the opportunity to finish the comment about this function.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-09-30 06:28:22 +02:00
Vicent Marti
6c8b458dcc mingw: Fix compilation warnings 2011-09-29 17:04:45 +02:00
Vicent Marti
6e34111e13 netops: Use pragmas only in MSVC 2011-09-29 16:30:38 +02:00
Vicent Marti
356f11feea index: Silence type-punned warning 2011-09-29 16:28:00 +02:00
Vicent Marti
780bea6e26 mingw: Fix printf identifiers 2011-09-29 16:23:24 +02:00
Vicent Marti
c103d7b4b7 odb: Pass compression settings to filebuf 2011-09-29 15:49:28 +02:00
Vicent Marti
8af4d074cc odb: Let users decide compression level for the loose ODB 2011-09-29 15:34:17 +02:00
Vicent Marti
72bdfdbc7c http-parser: Disable MSVC warnings locally 2011-09-29 15:25:22 +02:00
Carlos Martín Nieto
0812caaea5 Resync with upstream http-parser 2011-09-28 23:54:09 +02:00
Vicent Marti
5888860d2a msvc: Disable warnings in header file
Remove clutter from the CMakeLists file by disabling the warnings
programatically.
2011-09-28 23:49:55 +02:00
Vicent Marti
d215cf2429 http-parser: More type changes 2011-09-28 20:21:48 +02:00
Vicent Marti
59903b1fab Change types in http-parser 2011-09-28 19:41:33 +02:00
Vicent Marti
d02a7d8330 Update Clay 2011-09-28 18:57:32 +02:00
Vicent Martí
35e9407c46 Merge pull request #432 from carlosmn/msvc
Really fix MSVC
2011-09-27 11:14:23 -07:00
Carlos Martín Nieto
a5b0e7f8bc Really fix MSVC
These was left over from the previous PRs.

Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
2011-09-27 20:08:15 +02:00