gout

A static git page generator
git clone https://git.bracken.jp/gout.git
Log | Files | Refs | README | LICENSE

internal.h (1545B)


      1 #ifndef GOUT_GIT_INTERNAL_H_
      2 #define GOUT_GIT_INTERNAL_H_
      3 
      4 #include <git2.h>
      5 
      6 #include "git/commit.h"
      7 #include "git/delta.h"
      8 #include "git/file.h"
      9 #include "git/reference.h"
     10 #include "git/repo.h"
     11 #include "utils.h"
     12 
     13 GitCommit* gitcommit_create(const git_oid* oid, git_repository* repo);
     14 void gitcommit_free(GitCommit* commit);
     15 
     16 GitDelta* gitdelta_create(git_patch* patch);
     17 void gitdelta_free(GitDelta* delta);
     18 
     19 GitFile* gitfile_create(FileType type,
     20                         const char* mode,
     21                         const char* display_path,
     22                         const char* repo_path,
     23                         const char* commit_oid,
     24                         ssize_t size_bytes,
     25                         ssize_t size_lines,
     26                         const char* content);
     27 void gitfile_free(GitFile* file);
     28 
     29 char git_get_filetype(git_filemode_t m);
     30 char* git_format_filemode(git_filemode_t m);
     31 
     32 GitReference* gitreference_create(git_repository* repo, git_reference* ref);
     33 void gitreference_free(GitReference* ref);
     34 int gitreference_compare(const void* r1, const void* r2);
     35 
     36 void gitrepo_load_filesystem_metadata(GitRepo* repo,
     37                                       const FileSystem* fs,
     38                                       const char* path);
     39 GitRepo* gitrepo_create_from_repository(const FileSystem* fs,
     40                                         const char* path,
     41                                         void* git_repo);
     42 void gitrepo_free(GitRepo* repo);
     43 git_repository* gitrepo_open_repository(const char* path);
     44 
     45 #endif  // GOUT_GIT_INTERNAL_H_