diff options
author | mrb0nk500 <b0nk@b0nk.xyz> | 2021-06-15 20:31:53 -0400 |
---|---|---|
committer | mrb0nk500 <b0nk@b0nk.xyz> | 2021-06-15 20:31:53 -0400 |
commit | a0e2fef0f164ac3da9f6fac7aea96b91ceb64fa1 (patch) | |
tree | 69fefdf14d2a84b04275718b1d60bf6280d0f5c5 /git.h | |
parent | 129fcfb0e8f955970c9f82a0fcabcb8c6f2a1a0a (diff) |
Added the `git_branch` struct, and replaced all
instances of `git_reference` with it.
Diffstat (limited to 'git.h')
-rw-r--r-- | git.h | 10 |
1 files changed, 8 insertions, 2 deletions
@@ -8,6 +8,7 @@ typedef struct git_repo git_repo; typedef struct pull_request pull_request; typedef struct file file; typedef struct comment comment; +typedef struct git_branch git_branch; struct git_repo { git_repo *next; @@ -25,6 +26,11 @@ struct comment { int date; /* Date of creation. */ }; +struct git_branch { + char *name; /* Name of branch. */ + char *repo; /* Path, or URL to local, or remote repository. */ +}; + struct pull_request { char *title; /* Title of the pull request. */ char *desc; /* Description of the pull request. */ @@ -34,9 +40,9 @@ struct pull_request { uint8_t pr_type; /* Type of pull request. (0 = individual commit patches, 1 = remote branch) */ union { file **patches; /* Patch files of pull request. */ - git_reference *branch; /* Branch of pull request. */ + git_branch *branch; /* Branch of pull request. */ }; - git_reference *merge_branch; /* Branch to merge pull request with. */ + git_branch *merge_branch; /* Branch to merge pull request with. */ }; extern void cleanup_git(git_repository **repos); |