| Commit message (Collapse) | Author | Age | Files | Lines |
| |\
| |
| | |
Fix compilation error in MSVC when compiling for c++
|
| | | |
|
| | |
| |
| |
| |
| | |
Do not mess with environment variables anymore. The new external API has
more helper methods, and everything is explicit.
|
| | |
| |
| |
| |
| |
| |
| | |
If a config has several files, we need to check all of them before we
can say that a variable doesn't exist.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| | |
| |
| |
| |
| |
| |
| | |
It's not enough to load the config, we also need to explicitely parse
it after we create it.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| | |
| |
| |
| |
| |
| |
| | |
This function puts the global and repository configurations in one
git_config object and gives it to the user.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| |/
|
|
|
|
| |
Noticed by txdv
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| | |
|
| |\
| |
| | |
Plug memory leaks
|
| | |
| |
| |
| | |
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| | | |
|
| | | |
|
| |/
|
|
|
|
|
|
|
|
| |
There is no need to store the format outselves, as the library
provides git_filebuf_printf which takes care of the formatting itself.
Also get rid of an use of strcat + strcpy which is always a nice
thing.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| |
|
|
| |
Drop redundant methods. The ncmp method is now public
|
| |
|
|
|
| |
Yeah. Finally. Fuck the old names, this ain't POSIX
and they don't make any sense at all.
|
| |
|
|
| |
Same name as `git_config_foreach`
|
| |\
| |
| | |
Implement config writing
|
| | |
| |
| |
| |
| |
| |
| | |
Confg variables are indended using tags and not four spaces as was
being done by the code.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
After each variable gets set, we store it in our list (not completely
in the right position, but the close enough). Then we write out the
new config file in the same way that git.git does it (keep the rest of
the file intact and insert or replace the variable in its line).
Overwriting variables and adding new ones is supported (even on new
sections), though deleting isn't yet.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| | |
| |
| |
| |
| |
| |
| |
| | |
The section name should be stored in its case-sensitive variant when
we are adding a new variable. Use the internalize_section function to
do just that.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The (rather late) early-exit code, which provides a negligible
optimisation causes cvar_match_section to return false negatives when
it's called with a section name instead of a full variable name.
Remove this optimisation.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| | | |
|
| |\ \
| | |
| | | |
Fix: GIT_PATH_PATH_SEPARATOR is now a semi-colon under Windows.
|
| | | |
| | |
| | |
| | |
| | | |
GIT_PATH_LIST_SEPARATOR and GIT_PATH_MAX are made public so
that it's can be used by a client.
|
| |\ \ \
| | | |
| | | | |
Fix compilation warnings in MSVC
|
| | | | | |
|
| | | | | |
|
| |\ \ \ \
| | | | |
| | | | | |
Fix git_index_add()
|
| | |/ / / |
|
| | | | | |
|
| | | | |
| | | |
| | | |
| | | |
| | | | |
All the custom backend code will be moved to a separate project,
together with the new MySQL backend.
|
| |/ / /
| | |
| | |
| | |
| | |
| | |
| | | |
This header isn't needed at all and it shows a lot of warnings on
OpenBSD.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The better solution would probably be to turn the gitfo_lstat /
gitfo_readlink macros into real functions that wrap either lstat or
gitfo_lstat__w32 (and readlink or gitfo_readlink__w32). However, that
would introduce an indirection unless inlined. For now, this is the less
intrusive change.
|
| | | |
| | |
| | |
| | | |
MSVC supports "inline" only in C++ code, not in C code.
|
| | | | |
|
| | | | |
|
| | | | |
|
| |\ \ \
| | | |
| | | | |
git_tag_create{,_o,_frombuffer} correction and improvement
|
| | | | |
| | | |
| | | |
| | | | |
Now the code shoulb be c89.
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
writen to the odb
libgit2 has now the same behaviour of git when adding a tag with a
buffer.
|
| | | | |
| | | |
| | | |
| | | |
| | | | |
This commit create a function called tag_valid_in_odb which validate a
tag before its creation. This function will be needed by my next commit.
|
| | | | |
| | | |
| | | |
| | | |
| | | | |
When a tag already exists, it can be useful to directly have the oid
of the existed tag, just after trying to add it.
|
| | | | |
| | | |
| | | |
| | | | |
Before this commit, no message is shown when doing a git_lasterror().
|
| |\ \ \ \
| | | | |
| | | | | |
Commit short message should be the same as git's
|
| | | | | |
| | | | |
| | | | |
| | | | | |
In git, the short message of a commit is the part of the commit message before 2 consecutive line breaks. In the short message, line breaks are replaced by space characters.
|
| | | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Handle Symlinks if they can be handled in Win32. This is not even
compiled. Needs review.
The lstat implementation is modified from core Git.
The readlink implementation is modified from PHP.
|
| |\ \ \ \ \
| |/ / / /
|/| | | | |
Keep the lockfile if we fail to lock it
|
| | | |_|/
| |/| |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Add a check for the file descriptor in git_filebuf_cleanup. Without
it, an existing lockfile would be deleted if we tried to acquire it
(but failed, as the lockfile already existed).
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| |\ \ \ \
| | | | |
| | | | | |
Symlinks NEW
|
| | | | | | |
|