Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: rowanj/gitx
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 7921d5c98373504f3df804f49d93ad7e734edf06
Choose a base ref
..
head repository: rowanj/gitx
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: f2a05f094599a022387a4f41bf359e55ad15fae4
Choose a head ref
2 changes: 1 addition & 1 deletion Classes/Controllers/PBGitWindowController.m
Original file line number Diff line number Diff line change
@@ -112,7 +112,7 @@ - (void) changeContentController:(PBViewController *)controller
[[contentController view] setFrame:[contentSplitView bounds]];
[contentSplitView addSubview:[contentController view]];

[self setNextResponder: contentController];
// [self setNextResponder: contentController];
[[self window] makeFirstResponder:[contentController firstResponder]];
[contentController updateView];
[contentController addObserver:self forKeyPath:@"status" options:NSKeyValueObservingOptionInitial context:@"statusChange"];
18 changes: 10 additions & 8 deletions Classes/Controllers/PBHistorySearchController.m
Original file line number Diff line number Diff line change
@@ -438,23 +438,25 @@ - (void)parseBackgroundSearchResults:(NSNotification *)notification
[[NSNotificationCenter defaultCenter] removeObserver:self name:NSFileHandleReadToEndOfFileCompletionNotification object:[notification object]];
backgroundSearchTask = nil;

NSMutableIndexSet *indexes = [NSMutableIndexSet indexSet];
NSData *data = [[notification userInfo] valueForKey:NSFileHandleNotificationDataItem];

NSString *resultsString = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding];
NSArray *resultsArray = [resultsString componentsSeparatedByString:@"\n"];

NSMutableSet *matches = [NSMutableSet new];
for (NSString *resultSHA in resultsArray) {
NSUInteger index = 0;
for (PBGitCommit *commit in [commitController arrangedObjects]) {
if ([resultSHA isEqualToString:commit.OID.SHA]) {
[indexes addIndex:index];
break;
}
index++;
GTOID *resultOID = [GTOID oidWithSHA:resultSHA];
if (resultOID) {
[matches addObject:resultOID];
}
}

NSArray *arrangedObjects = [commitController arrangedObjects];
NSIndexSet *indexes = [arrangedObjects indexesOfObjectsPassingTest:^BOOL(id obj, NSUInteger idx, BOOL *stop) {
PBGitCommit *commit = obj;
return [matches containsObject:commit.OID];
}];

results = indexes;
[self clearProgressIndicator];
[self updateSelectedResult];
2 changes: 1 addition & 1 deletion Classes/Views/GLFileView.m
Original file line number Diff line number Diff line change
@@ -246,7 +246,7 @@ - (NSString *) parseBlame:(NSString *)txt

int n;
for(n=1;n<nLines;n++){
line=[lines objectAtIndex:i++];
i++;
do{
line=[lines objectAtIndex:i++];
}while([line characterAtIndex:0]!='\t');
7 changes: 5 additions & 2 deletions Classes/git/PBGitCommit.m
Original file line number Diff line number Diff line change
@@ -115,12 +115,15 @@ - (NSString *)SVNRevision

- (GTOID *)OID
{
return self.gtCommit.OID;
if (!_oid) {
_oid = self.gtCommit.OID;
}
return _oid;
}

- (NSString *)SHA
{
return self.gtCommit.SHA;
return self.OID.SHA;
}

- (BOOL) isOnSameBranchAs:(PBGitCommit *)otherCommit
5 changes: 5 additions & 0 deletions Classes/git/PBGitRepository.m
Original file line number Diff line number Diff line change
@@ -333,6 +333,11 @@ - (void) reloadRefs

NSError* error = nil;
NSArray* allRefs = [self.gtRepo referenceNamesWithError:&error];

if ([self.gtRepo isHEADDetached]) {
// Add HEAD when we're detached
allRefs = [allRefs arrayByAddingObject:@"HEAD"];
}

// load all named refs
NSMutableOrderedSet *oldBranches = [self.branchesSet mutableCopy];
6 changes: 6 additions & 0 deletions updates/GitX-dev.html
Original file line number Diff line number Diff line change
@@ -12,11 +12,17 @@ <h1>GitX-dev Release Notes</h1>
<p>Recent changes made to <a href="https://github.com/rowanj/gitx">GitX-dev</a></p>
</header>
<section>
<h2>Changes since 0.15.1962</h2>
<ul>
<li>Break responder loop that crashes repository window on OS X 10.10</li>
</ul>

<h2>Changes since 0.15.1949</h2>
<ul>
<li>Fix crash when trying to browse for a remote (<a href="https://github.com/rowanj/gitx/issues/255">#255</a>, <a href="https://github.com/rowanj/gitx/pull/370">#370</a>)</li>
<li>Fix changes to newly added files never showing up in the commit view.</li>
<li>Merge <a href="https://github.com/rowanj/gitx/pull/367">pull request #367</a> (<a href="https://github.com/Debilski">Debilski</a>): Stylistic typographic changes.</li>
<li>Make commit searches that include a lot of results exponentially faster.</li>
</ul>

<h2>Changes since 0.15.1899</h2>