summaryrefslogtreecommitdiff
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* repository: parse init.templatedir as a pathcmn/template-pathCarlos Martín Nieto2015-02-061-1/+2
| | | | | This is a path so we must use the path getter so we get the tilde expansion done.
* Merge pull request #2867 from ethomson/8dot3Edward Thomson2015-02-051-1/+2
|\ | | | | Handle 8dot3 filenames being disabled on Win32
| * win32: cleanup 8.3 disabled testsEdward Thomson2015-02-031-1/+2
| |
| * Fix test failures when 8.3 is disabledLinquize2015-01-311-1/+1
| |
* | hash_generic: __extension__ keyword for pedantryEdward Thomson2015-02-041-1/+1
| |
* | bswap: remove unused bswapEdward Thomson2015-02-032-98/+0
|/
* Merge pull request #2819 from libgit2/cmn/config-get-pathEdward Thomson2015-01-261-0/+41
|\ | | | | config: add parsing and getter for paths
| * config: add parsing and getter for pathscmn/config-get-pathCarlos Martín Nieto2015-01-141-0/+41
| |
* | Merge pull request #2837 from swisspol/set_indexEdward Thomson2015-01-261-1/+1
|\ \ | | | | | | Allow passing a NULL index to git_repository_set_index()
| * | Allow passing a NULL index to git_repository_set_index()Pierre-Olivier Latour2015-01-231-1/+1
| | | | | | | | | | | | | | | | | | This is supported by the underlying set_index() implementation and setting the repository index to NULL is recommended by the git_repository_set_bare() documentation.
* | | Merge pull request #2847 from jacquesg/coverityEdward Thomson2015-01-263-1/+8
|\ \ \ | | | | | | | | More coverity fixes
| * | | Ensure the diff hunk callback is specified before trying to dereference itJacques Germishuys2015-01-251-1/+2
| | | |
| * | | Return early if allocating a git_pathspec_match_list failedJacques Germishuys2015-01-251-0/+3
| | | |
| * | | Ensure git_index_entry is not NULL before trying to free itJacques Germishuys2015-01-251-0/+3
| | | |
* | | | Merge pull request #2841 from swisspol/set_bareEdward Thomson2015-01-261-1/+1
|\ \ \ \ | | | | | | | | | | Fixed git_repository_set_bare() not setting "core.bare" correctly
| * | | | Fixed git_repository_set_bare() not setting "core.bare" correctlyPierre-Olivier Latour2015-01-231-1/+1
| | |/ / | |/| |
* | | | Merge pull request #2844 from rakuco/netinet-include-fixesEdward Thomson2015-01-261-0/+3
|\ \ \ \ | | | | | | | | | | openssl: Add all required includes for AF_INET6 and in6_addr.
| * | | | openssl: Add all required includes for AF_INET6 and in6_addr.Raphael Kubo da Costa2015-01-241-0/+3
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes the build at least on FreeBSD, where those types were not defined indirectly: src/openssl_stream.c:100:18: error: variable has incomplete type 'struct in6_addr' struct in6_addr addr6; ^ src/openssl_stream.c:100:9: note: forward declaration of 'struct in6_addr' struct in6_addr addr6; ^ src/openssl_stream.c:111:18: error: use of undeclared identifier 'AF_INET' if (p_inet_pton(AF_INET, host, &addr4)) { ^ src/unix/posix.h:31:40: note: expanded from macro 'p_inet_pton' ^ src/openssl_stream.c:115:18: error: use of undeclared identifier 'AF_INET6' if(p_inet_pton(AF_INET6, host, &addr6)) { ^ src/unix/posix.h:31:40: note: expanded from macro 'p_inet_pton' ^
* | | | pathspec: do not try to dereference NULLBoris Egorov2015-01-251-0/+3
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | pathspec_match_free() should not dereference a NULL passed to it. I found this issue when I tried to run example log program with nonexistent branch: ./example/log help Such call leads to segmentation fault.
* | | checkout: free last created directoryEdward Thomson2015-01-231-0/+1
|/ /
* | Merge pull request #2829 from jacquesg/dead-codeEdward Thomson2015-01-212-2/+2
|\ \ | | | | | | Remove logically dead code (we're already asserting)
| * | Treat a NULL string as if it's emptyJacques Germishuys2015-01-201-1/+1
| | |
| * | Remove logically dead code (we're already asserting)Jacques Germishuys2015-01-201-1/+1
| | |
* | | checkout: remove files before writing new onesEdward Thomson2015-01-203-25/+100
| | | | | | | | | | | | | | | | | | | | | On case insensitive filesystems, we may have files in the working directory that case fold to a name we want to write. Remove those files (by default) so that we will not end up with a filename that has the unexpected case.
* | | checkout: drop newline in error messageEdward Thomson2015-01-201-1/+1
| | |
* | | checkout: don't recreate previous directoryEdward Thomson2015-01-201-3/+19
| | | | | | | | | | | | | | | Don't bother trying to recreate the previously created directory during checkout, for a modest reduction in the number of stats.
* | | mkdir: walk up tree to mkdirEdward Thomson2015-01-201-11/+25
| | | | | | | | | | | | | | | | | | Walk up the tree to mkdir, which is less immediately efficient, but allows us to look at intermediate directories that may need attention.
* | | git_path_join_unrooted: return base lenEdward Thomson2015-01-203-15/+34
| | | | | | | | | | | | | | | | | | | | | The documentation for `git_path_join_unrooted` states that the base length will be returned, so that consumers like checkout know where to start creating directories instead of always creating directories at the directory root.
* | | checkout: introduce git_checkout_perfdataEdward Thomson2015-01-203-50/+130
| | | | | | | | | | | | | | | Checkout can now provide performance data about the number of (some) syscalls performed using an optional callback.
* | | Make binary detection work similar to vanilla gitSven Strickroth2015-01-201-1/+4
|/ / | | | | | | | | | | Main change: Don't treat chars > 128 as non-printable (common in UTF-8 files) Signed-off-by: Sven Strickroth <email@cs-ware.de>
* | diff: only compute patches when requestedEdward Thomson2015-01-201-5/+6
| | | | | | | | | | When we're called with no hunk or line callback, we don't need to do the hunk or line computation.
* | Remove strlen() calls from loop conditionMaks Naumov2015-01-151-1/+1
|/ | | | Avoid str length recalculation every iteration
* Merge branch 'pr/2740'Edward Thomson2015-01-143-44/+28
|\
| * Always use GIT_HASHSIG_SMART_WHITESPACE when diffing for mergesPierre-Olivier Latour2015-01-141-7/+1
| | | | | | | | git_merge_tree_flag_t cannot contain any GIT_DIFF_FIND_xxx flags so there's not point in checking for them
| * Added GIT_HASHSIG_ALLOW_SMALL_FILES to allow computing signatures for small ↵Pierre-Olivier Latour2015-01-142-37/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | files The implementation of the hashsig API disallows computing a signature on small files containing only a few lines. This new flag disables this behavior. git_diff_find_similar() sets this flag by default which means that rename / copy detection of small files will now work. This in turn affects the behavior of the git_status and git_blame APIs which will now detect rename of small files assuming the right options are passed.
* | Merge commit '4b1018d24f980273528743c27c47ceb96cb720bd'Carlos Martín Nieto2015-01-091-1/+2
|\ \ | | | | | | | | | Fix crash in free() when git_buf_grow() fails.
| * | Fix crash in free() when git_buf_grow() fails.Jeff Hostetler2015-01-091-1/+2
| | |
* | | remote: plug leakEdward Thomson2015-01-081-5/+5
| | |
* | | Merge pull request #2802 from calavera/remote_create_prune_configEdward Thomson2015-01-081-13/+33
|\ \ \ | | | | | | | | Load prune configuration when a remote is created.
| * | | Fix intentation.David Calavera2015-01-051-1/+1
| | | |
| * | | Load prune configuration when a remote is created.David Calavera2015-01-051-14/+34
| | | |
* | | | Add extern function to initialize submodule update options.David Calavera2015-01-071-0/+7
| | | |
* | | | submodule: declare vars at top of func blockEdward Thomson2015-01-061-1/+4
| | | |
* | | | Merge commit 'refs/pull/2632/head' of github.com:libgit2/libgit2Carlos Martín Nieto2015-01-051-18/+219
|\ \ \ \ | |/ / / |/| | |
| * | | Introduce a convenience function for submodule updatejamill/submodule_updateJameson Miller2014-12-221-10/+197
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This introduces the functionality of submodule update in 'git_submodule_do_update'. The existing 'git_submodule_update' function is renamed to 'git_submodule_update_strategy'. The 'git_submodule_update' function now refers to functionality similar to `git submodule update`, while `git_submodule_update_strategy` is used to get the configured value of submodule.<name>.update.
| * | | submodule init should resolve relative url pathsJameson Miller2014-12-221-10/+24
| | |/ | |/| | | | | | | | | | Submodule init should handle relative paths in .gitmodules files and resolve these urls when updating the git config file.
* | | Fixed internal push state not being cleared on downloadPierre-Olivier Latour2015-01-011-0/+5
| |/ |/| | | | | git_remote_download() must also clear the internal push state resulting from a possible earlier push operation. Otherwise calling git_remote_update_tips() will execute the push version instead of the fetch version and among other things, tags won't be updated.
* | Merge pull request #2761 from libgit2/cmn/fetch-pruneEdward Thomson2014-12-302-0/+168
|\ \ | | | | | | Remote-tracking branch prunning
| * | fetch: remove the prune setterCarlos Martín Nieto2014-12-141-5/+0
| | | | | | | | | | | | | | | | | | | | | | | | This option does not get persisted to disk, which makes it different from the rest of the setters. Remove it until we go all the way. We still respect the configuration option, and it's still possible to perform a one-time prune by calling the function.
| * | fetch: perform prune in separate stepsCarlos Martín Nieto2014-12-141-45/+112
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For each remote-tracking branch we want to remove, we need to consider it against every other refspec in case we have overlapping refspecs, such as with refs/heads/*:refs/remotes/origin/* refs/pull/*/head:refs/remotes/origin/pr/* as we'd otherwise remove too many refspecs. Create a list of condidates, which are the references matching the rhs of any active refspec and then filter that list by removing those entries for which we find a remove reference with any active refspec. Those which are left after this are removed.