func (remote *Remote) Connect(direction Direction) error { ecode := C.git_remote_connect(remote.git_remote, C.int(direction)) if ecode != git_SUCCESS { return gitError() } return nil }
func (o *Remote) Connect(direction ConnectDirection) error { runtime.LockOSThread() defer runtime.UnlockOSThread() if ret := C.git_remote_connect(o.ptr, C.git_direction(direction)); ret != 0 { return MakeGitError(ret) } return nil }
func (o *Remote) Connect(direction ConnectDirection, callbacks *RemoteCallbacks) error { var ccallbacks C.git_remote_callbacks populateRemoteCallbacks(&ccallbacks, callbacks) runtime.LockOSThread() defer runtime.UnlockOSThread() if ret := C.git_remote_connect(o.ptr, C.git_direction(direction), &ccallbacks); ret != 0 { return MakeGitError(ret) } return nil }