File tree Expand file tree Collapse file tree 2 files changed +5
-0
lines changed Expand file tree Collapse file tree 2 files changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -50,6 +50,7 @@ NS_ASSUME_NONNULL_BEGIN
5050@property (nonatomic , readonly ) GTBranchType branchType;
5151@property (nonatomic , readonly , strong ) GTRepository *repository;
5252@property (nonatomic , readonly , strong ) GTReference *reference;
53+ @property (nonatomic , readonly , getter =isHEAD) BOOL HEAD;
5354
5455+ (NSString *)localNamePrefix ;
5556+ (NSString *)remoteNamePrefix ;
Original file line number Diff line number Diff line change @@ -152,6 +152,10 @@ - (GTBranchType)branchType {
152152 }
153153}
154154
155+ - (BOOL )isHEAD {
156+ return (git_branch_is_head (self.reference .git_reference ) ? YES : NO );
157+ }
158+
155159- (NSArray *)uniqueCommitsRelativeToBranch : (GTBranch *)otherBranch error : (NSError **)error {
156160 GTEnumerator *enumerator = [self .repository enumeratorForUniqueCommitsFromOID: self .OID relativeToOID: otherBranch.OID error: error];
157161 return [enumerator allObjectsWithError: error];
You can’t perform that action at this time.
0 commit comments