summaryrefslogtreecommitdiff
path: root/tests/network/remote/defaultbranch.c
Commit message (Collapse)AuthorAgeFilesLines
* Tell the git_transport about the custom_headersMatt Burke2015-09-081-3/+3
|
* Remove the callbacks struct from the remoteCarlos Martín Nieto2015-05-131-3/+3
| | | | | | | | | | | | | | Having the setting be different from calling its actions was not a great idea and made for the sake of the wrong convenience. Instead of that, accept either fetch options, push options or the callbacks when dealing with the remote. The fetch options are currently only the callbacks, but more options will be moved from setters and getters on the remote to the options. This does mean passing the same struct along the different functions but the typical use-case will only call git_remote_fetch() or git_remote_push() and so won't notice much difference.
* repository: remove log message override for switching the active branchCarlos Martín Nieto2015-03-031-3/+3
| | | | | | We want to use the "checkout: moving from ..." message in order to let git know when a change of branch has happened. Make the convenience functions for this goal write this message.
* Remove the signature from ref-modifying functionsCarlos Martín Nieto2015-03-031-5/+5
| | | | | | | | | | The signature for the reflog is not something which changes dynamically. Almost all uses will be NULL, since we want for the repository's default identity to be used, making it noise. In order to allow for changing the identity, we instead provide git_repository_set_ident() and git_repository_ident() which allow a user to override the choice of signature.
* clone: correct handling of an unborn HEADCarlos Martín Nieto2014-09-021-0/+15
| | | | | If the remote does not advertise HEAD, then it is unborn and we cannot checkout that branch. Handle it the same way as an empty repo.
* remote: add tests for remote-branch edge casesCarlos Martín Nieto2014-09-021-0/+29
| | | | | | Add tests for the case when there are no branches on the remote and when HEAD is detached but has the id of a non-branch. In both of these cases, we should return ENOTFOUND.
* remote: assert what we want to happen when ther is no default branchCarlos Martín Nieto2014-08-291-0/+14
| | | | Assert what we already do, so as to notice changes.
* remote: add api to guess the remote's default branchCarlos Martín Nieto2014-05-211-0/+50
If the remote supports the symref protocol extension, then we return that, otherwise we guess with git's rules.