Created
November 19, 2008 13:49
-
-
Save pieter/26515 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 7bea3778341db2cbed91cf51c6306cd95ed7e0e4 Mon Sep 17 00:00:00 2001 | |
From: Pieter de Bie <pdebie@ai.rug.nl> | |
Date: Wed, 19 Nov 2008 14:45:33 +0100 | |
Subject: [PATCH] Test2 | |
--- | |
PBEasyPipe.m | 2 +- | |
PBGitCommit.m | 5 +++-- | |
2 files changed, 4 insertions(+), 3 deletions(-) | |
diff --git a/PBEasyPipe.m b/PBEasyPipe.m | |
index b18c12e..1fe7f37 100644 | |
--- a/PBEasyPipe.m | |
+++ b/PBEasyPipe.m | |
@@ -106,7 +106,7 @@ | |
NSData* data = [handle readDataToEndOfFile]; | |
NSString* string = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; | |
- [task waitUntilExit]; | |
+ | |
// Strip trailing newline | |
if ([string hasSuffix:@"\n"]) | |
string = [string substringToIndex:[string length]-1]; | |
diff --git a/PBGitCommit.m b/PBGitCommit.m | |
index f38bf43..8e9a50d 100644 | |
--- a/PBGitCommit.m | |
+++ b/PBGitCommit.m | |
@@ -40,8 +40,9 @@ | |
if (details != nil) | |
return details; | |
- details = [self.repository outputForCommand:[@"show --pretty=raw " stringByAppendingString:self.sha]]; | |
- | |
+ NSFileHandle* handle = [self.repository handleForCommand:[@"show --pretty=raw " stringByAppendingString:self.sha]]; | |
+ details = [[NSString alloc] initWithData:[handle readDataToEndOfFile] encoding: NSUTF8StringEncoding]; | |
+ | |
return details; | |
} | |
-- | |
1.6.0.3.875.g5bf73+GitX |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment