libgit2/libgit2sharp — pull request #260 by ben (2012-11-29 03:46:02+00:00)
Title: The Great Libgit2 Renaming of 2012

## WIP – do not merge

:construction: :construction_worker: :construction:

Adjust to all the renamed/reorganized APIs as of https://github.com/libgit2/libgit2/commit/64c5112188647fcbfbe2bbfb897abfbc21912ba8.

This is based from #259, so that should be merged before this. There are two failing tests; one is `ResetHeadFixture.HardResetInABareRepositoryThrows`, which is a known issue, and needs correcting in libgit2. The other is this:

```
LibGit2Sharp.Tests.NoteFixture.CreatingANoteWhichAlreadyExistsOverwritesThePreviousNote
System.Runtime.InteropServices.MarshalDirectiveException
Cannot marshal 'parameter #1': This type can only be marshaled in restricted ways.
at System.Runtime.InteropServices.Marshal.GetFunctionPointerForDelegateInternal(Delegate d)
at LibGit2Sharp.Core.NativeMethods.git_note_foreach(RepositorySafeHandle repo, String notes_ref, git_note_foreach_cb cb, IntPtr payload)
at LibGit2Sharp.Core.Proxy.<>c__DisplayClass14`1.b__12(Func`4 c) in Proxy.cs: line 798
at LibGit2Sharp.Core.Proxy.git_foreach(Func`3 resultSelector, Func`2 iterator) in Proxy.cs: line 1713
at LibGit2Sharp.Core.Proxy.git_note_foreach(RepositorySafeHandle repo, String notes_ref, Func`3 resultSelector) in Proxy.cs: line 798
at LibGit2Sharp.NoteCollection.get_Item(String namespace) in NoteCollection.cs: line 115
at LibGit2Sharp.Tests.NoteFixture.CanRetrieveTheListOfNotesForAGivenNamespace() in NoteFixture.cs: line 236
```

...which I've never seen before. I'd appreciate any help (ahem, @nulltoken & @jamill).