From 9d0d814f19e9d31caeeb68abce84f9eba9659737 Mon Sep 17 00:00:00 2001 From: Jesse Ezell Date: Tue, 1 Apr 2014 11:06:47 -0700 Subject: rename inmemory to anonymous remote --- remote_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'remote_test.go') diff --git a/remote_test.go b/remote_test.go index 90e24ae..37ed8c3 100644 --- a/remote_test.go +++ b/remote_test.go @@ -10,7 +10,7 @@ func TestRefspecs(t *testing.T) { defer os.RemoveAll(repo.Workdir()) defer repo.Free() - remote, err := repo.CreateRemoteInMemory("refs/heads/*:refs/heads/*", "git://foo/bar") + remote, err := repo.CreateAnonymousRemote("refs/heads/*:refs/heads/*", "git://foo/bar") checkFatal(t, err) expected := []string{ -- cgit v1.2.3 From 9cd1d129bcd567ef65137783a603f8d898d8d933 Mon Sep 17 00:00:00 2001 From: Carlos Martín Nieto Date: Tue, 1 Apr 2014 20:10:20 +0200 Subject: Remote: The whole point of the anonymous change Was that it would break and we'd remember that the order changed. Oh well. --- remote.go | 4 ++-- remote_test.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'remote_test.go') diff --git a/remote.go b/remote.go index da04d2a..eb5d7a7 100644 --- a/remote.go +++ b/remote.go @@ -184,7 +184,7 @@ func (repo *Repository) CreateRemoteWithFetchspec(name string, url string, fetch return remote, nil } -func (repo *Repository) CreateAnonymousRemote(fetch string, url string) (*Remote, error) { +func (repo *Repository) CreateAnonymousRemote(url, fetch string) (*Remote, error) { remote := &Remote{} curl := C.CString(url) @@ -195,7 +195,7 @@ func (repo *Repository) CreateAnonymousRemote(fetch string, url string) (*Remote runtime.LockOSThread() defer runtime.UnlockOSThread() - ret := C.git_remote_create_anonymous(&remote.ptr, repo.ptr, cfetch, curl) + ret := C.git_remote_create_anonymous(&remote.ptr, repo.ptr, curl, cfetch) if ret < 0 { return nil, MakeGitError(ret) } diff --git a/remote_test.go b/remote_test.go index 37ed8c3..7cef1ec 100644 --- a/remote_test.go +++ b/remote_test.go @@ -10,7 +10,7 @@ func TestRefspecs(t *testing.T) { defer os.RemoveAll(repo.Workdir()) defer repo.Free() - remote, err := repo.CreateAnonymousRemote("refs/heads/*:refs/heads/*", "git://foo/bar") + remote, err := repo.CreateAnonymousRemote("git://foo/bar", "refs/heads/*:refs/heads/*") checkFatal(t, err) expected := []string{ -- cgit v1.2.3