Ejemplo n.º 1
0
 public static extern unsafe int git_filter_list_load(
     out git_filter_list *filters,
     git_repository *repo,
     git_blob *blob,
     [MarshalAs(UnmanagedType.CustomMarshaler, MarshalCookie = Utf8Marshaler.ToNative, MarshalTypeRef = typeof(Utf8Marshaler))] string path,
     git_filter_mode_t mode,
     uint flags);
Ejemplo n.º 2
0
 public static extern unsafe int git_config_add_file_ondisk(
     git_config *cfg,
     [MarshalAs(CustomMarshaler, MarshalCookie = NativeCookie, MarshalTypeRef = typeof(U8StringMarshaler))]
     string path,
     git_config_level_t level,
     git_repository *repo,
     int force);
Ejemplo n.º 3
0
 internal unsafe override void Dispose(bool disposing)
 {
     if (nativeRepository != null)
     {
         libgit2.git_repository_free(nativeRepository);
         nativeRepository = null;
     }
 }
Ejemplo n.º 4
0
        private unsafe Repository(git_repository *nativeRepository)
        {
            Ensure.NativePointerNotNull(nativeRepository);
            this.nativeRepository = nativeRepository;

            path    = new LazyNative <string>(() => libgit2.git_repository_path(this.nativeRepository), this);
            workdir = new LazyNative <string>(() => libgit2.git_repository_workdir(this.nativeRepository), this);

            isBare = new LazyNative <bool>(() => libgit2.git_repository_is_bare(this.nativeRepository) == 0 ? false : true, this);

            objects    = new Lazy <ObjectCollection>(() => new ObjectCollection(this));
            references = new Lazy <ReferenceCollection>(() => new ReferenceCollection(this));
        }
Ejemplo n.º 5
0
 public static extern unsafe int git_tree_lookup(out git_tree *obj, git_repository *repo, ref git_oid id);
Ejemplo n.º 6
0
 public static extern unsafe int git_clone(
     out git_repository *repo,
     [MarshalAs(UnmanagedType.CustomMarshaler, MarshalCookie = Utf8Marshaler.ToNative, MarshalTypeRef = typeof(Utf8Marshaler))] string remotePath,
     [MarshalAs(UnmanagedType.CustomMarshaler, MarshalCookie = Utf8Marshaler.ToNative, MarshalTypeRef = typeof(Utf8Marshaler))] string localPath,
     git_clone_options *options);
Ejemplo n.º 7
0
 public static extern unsafe int git_reference_iterator_new(out git_reference_iterator *iterator, git_repository *repository);
Ejemplo n.º 8
0
 public static extern unsafe int git_reference_lookup(
     out git_reference *reference,
     git_repository *repo,
     [MarshalAs(UnmanagedType.CustomMarshaler, MarshalCookie = Utf8Marshaler.ToNative, MarshalTypeRef = typeof(Utf8Marshaler))] string name);
Ejemplo n.º 9
0
 public static extern unsafe void git_repository_free(git_repository *repo);
Ejemplo n.º 10
0
 public static extern unsafe string git_repository_workdir(git_repository *repository);
Ejemplo n.º 11
0
 public static extern unsafe int git_blob_lookup(out git_blob *blob, git_repository *repo, ref git_oid id);
Ejemplo n.º 12
0
 public static extern unsafe int git_repository_head_detached(
     git_repository *repo);
Ejemplo n.º 13
0
 public static extern unsafe int git_repository_odb(out git_odb *odb, git_repository *repo);
Ejemplo n.º 14
0
 internal RepositoryHandle(git_repository *ptr, bool owned)
     : base((void *)ptr, owned)
 {
 }
Ejemplo n.º 15
0
 public static extern unsafe int git_repository_new(out git_repository *repo);
Ejemplo n.º 16
0
 public static extern unsafe int git_repository_index(out git_index *index, git_repository *repo);
Ejemplo n.º 17
0
 public static extern unsafe int git_repository_is_bare(
     git_repository *repo);
Ejemplo n.º 18
0
 public static extern unsafe int git_object_lookup(out git_object *obj, git_repository *repo, ref git_oid id, git_object_t type);
Ejemplo n.º 19
0
 public static extern unsafe void git_repository_set_odb(git_repository *repo, git_odb *odb);
Ejemplo n.º 20
0
 public static extern unsafe int git_repository_open(
     out git_repository *repo,
     [MarshalAs(UnmanagedType.CustomMarshaler, MarshalCookie = Utf8Marshaler.ToNative, MarshalTypeRef = typeof(Utf8Marshaler))] string path);
Ejemplo n.º 21
0
 public static extern unsafe int git_repository_head(
     out git_reference *reference, git_repository *repo);
Ejemplo n.º 22
0
 public static extern unsafe string git_repository_path(git_repository *repository);
Ejemplo n.º 23
0
 public static extern unsafe int git_filter_list_apply_to_file(git_buf outputBuffer, git_filter_list *filters, git_repository *repo, string path);