Skip to content

Commit

Permalink
Merge pull request #145 from lindegroup/1.0.4-rc
Browse files Browse the repository at this point in the history
Merging 1.0.4 release candidate into master branch.
  • Loading branch information
homebysix committed Sep 24, 2014
2 parents a6f804e + 51df3fb commit f3394fc
Show file tree
Hide file tree
Showing 45 changed files with 1,422 additions and 1,201 deletions.
25 changes: 24 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,26 @@
*xcuserdata*
# CocoaPods
Pods/

# Finder
.DS_Store

# TaskPaper
*.taskpaper

# Xcode
build/
*.pbxuser
!default.pbxuser
*.mode1v3
!default.mode1v3
*.mode2v3
!default.mode2v3
*.perspectivev3
!default.perspectivev3
xcuserdata
*.xccheckout
*.moved-aside
DerivedData
*.hmap
*.ipa
*.xcuserstate
111 changes: 93 additions & 18 deletions AutoPkgr.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<dict>
<key>026F280F-1C98-4936-9C8C-43DE0D2802B2</key>
<string>https://github.com/MailCore/mailcore2.git</string>
<key>BE02C102-5A70-48C2-A395-81BCE2455E30</key>
<key>941A3B01BA9BA1841C1477B8E57AB717E0D7F561</key>
<string>https://github.com/lindegroup/autopkgr.git</string>
</dict>
<key>IDESourceControlProjectPath</key>
Expand All @@ -21,22 +21,22 @@
<dict>
<key>026F280F-1C98-4936-9C8C-43DE0D2802B2</key>
<string>../../mailcore2</string>
<key>BE02C102-5A70-48C2-A395-81BCE2455E30</key>
<key>941A3B01BA9BA1841C1477B8E57AB717E0D7F561</key>
<string>../..</string>
</dict>
<key>IDESourceControlProjectURL</key>
<string>https://github.com/lindegroup/autopkgr.git</string>
<key>IDESourceControlProjectVersion</key>
<integer>110</integer>
<integer>111</integer>
<key>IDESourceControlProjectWCCIdentifier</key>
<string>BE02C102-5A70-48C2-A395-81BCE2455E30</string>
<string>941A3B01BA9BA1841C1477B8E57AB717E0D7F561</string>
<key>IDESourceControlProjectWCConfigurations</key>
<array>
<dict>
<key>IDESourceControlRepositoryExtensionIdentifierKey</key>
<string>public.vcs.git</string>
<key>IDESourceControlWCCIdentifierKey</key>
<string>BE02C102-5A70-48C2-A395-81BCE2455E30</string>
<string>941A3B01BA9BA1841C1477B8E57AB717E0D7F561</string>
<key>IDESourceControlWCCName</key>
<string>autopkgr</string>
</dict>
Expand Down
1 change: 1 addition & 0 deletions AutoPkgr.xcworkspace/contents.xcworkspacedata

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

41 changes: 41 additions & 0 deletions AutoPkgr.xcworkspace/xcshareddata/AutoPkgr.xccheckout
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDESourceControlProjectFavoriteDictionaryKey</key>
<false/>
<key>IDESourceControlProjectIdentifier</key>
<string>84348D8E-D7BC-4CA9-AEDD-70D13CE8F3BB</string>
<key>IDESourceControlProjectName</key>
<string>AutoPkgr</string>
<key>IDESourceControlProjectOriginsDictionary</key>
<dict>
<key>540ED53D-E2BD-4E89-B7A2-52E63D5288B4</key>
<string>https://github.com/lindegroup/autopkgr.git</string>
</dict>
<key>IDESourceControlProjectPath</key>
<string>AutoPkgr.xcworkspace</string>
<key>IDESourceControlProjectRelativeInstallPathDictionary</key>
<dict>
<key>540ED53D-E2BD-4E89-B7A2-52E63D5288B4</key>
<string>..</string>
</dict>
<key>IDESourceControlProjectURL</key>
<string>https://github.com/lindegroup/autopkgr.git</string>
<key>IDESourceControlProjectVersion</key>
<integer>110</integer>
<key>IDESourceControlProjectWCCIdentifier</key>
<string>540ED53D-E2BD-4E89-B7A2-52E63D5288B4</string>
<key>IDESourceControlProjectWCConfigurations</key>
<array>
<dict>
<key>IDESourceControlRepositoryExtensionIdentifierKey</key>
<string>public.vcs.git</string>
<key>IDESourceControlWCCIdentifierKey</key>
<string>540ED53D-E2BD-4E89-B7A2-52E63D5288B4</string>
<key>IDESourceControlWCCName</key>
<string>AutoPkgr</string>
</dict>
</array>
</dict>
</plist>
6 changes: 4 additions & 2 deletions AutoPkgr/AutoPkgr-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0.3</string>
<string>1.0.4</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>7</string>
<string>384</string>
<key>LSApplicationCategoryType</key>
<string>public.app-category.utilities</string>
<key>LSMinimumSystemVersion</key>
Expand All @@ -32,5 +32,7 @@
<string>MainMenu</string>
<key>NSPrincipalClass</key>
<string>NSApplication</string>
<key>SUFeedURL</key>
<string>https://raw.githubusercontent.com/lindegroup/autopkgr/appcast/appcast.xml</string>
</dict>
</plist>
21 changes: 17 additions & 4 deletions AutoPkgr/Base.lproj/MainMenu.xib
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="5056" systemVersion="13E28" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="6245" systemVersion="13F34" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
<dependencies>
<deployment defaultVersion="1080" identifier="macosx"/>
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="5056"/>
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="6245"/>
</dependencies>
<objects>
<customObject id="-2" userLabel="File's Owner" customClass="NSApplication">
Expand All @@ -11,13 +10,14 @@
</connections>
</customObject>
<customObject id="-1" userLabel="First Responder" customClass="FirstResponder"/>
<customObject id="-3" userLabel="Application"/>
<customObject id="-3" userLabel="Application" customClass="NSObject"/>
<customObject id="Voe-Tx-rLC" customClass="LGAppDelegate">
<connections>
<outlet property="statusMenu" destination="VXP-Yr-lJz" id="35U-ad-DRr"/>
</connections>
</customObject>
<customObject id="YLy-65-1bz" customClass="NSFontManager"/>
<customObject id="MZ8-j7-lrs" customClass="SUUpdater"/>
<menu title="Main Menu" systemMenu="main" id="AYu-sK-qS6">
<items>
<menuItem title="AutoPkgr" id="1Xt-HY-uBw">
Expand All @@ -30,6 +30,12 @@
<action selector="orderFrontStandardAboutPanel:" target="-1" id="Exp-CZ-Vem"/>
</connections>
</menuItem>
<menuItem title="Check For Updates..." id="3R2-hO-YyK">
<modifierMask key="keyEquivalentModifierMask"/>
<connections>
<action selector="checkForUpdates:" target="MZ8-j7-lrs" id="a2q-WD-JPE"/>
</connections>
</menuItem>
<menuItem isSeparatorItem="YES" id="VOq-y0-SEH"/>
<menuItem title="Preferences…" keyEquivalent="," id="BOF-NM-1cW"/>
<menuItem isSeparatorItem="YES" id="wFC-TO-SCJ"/>
Expand Down Expand Up @@ -681,6 +687,12 @@
<action selector="showConfigurationWindow:" target="Voe-Tx-rLC" id="q4g-vL-fgF"/>
</connections>
</menuItem>
<menuItem title="Verbose Logs" alternate="YES" id="Y3C-Qa-kUT">
<modifierMask key="keyEquivalentModifierMask" option="YES"/>
<connections>
<binding destination="SYv-Ba-SbG" name="value" keyPath="values.debug" id="Cb3-Sl-N5Q"/>
</connections>
</menuItem>
<menuItem isSeparatorItem="YES" id="5vA-zg-b1N"/>
<menuItem title="Quit AutoPkgr" id="cuo-db-FBC">
<modifierMask key="keyEquivalentModifierMask"/>
Expand All @@ -690,5 +702,6 @@
</menuItem>
</items>
</menu>
<userDefaultsController representsSharedInstance="YES" id="SYv-Ba-SbG"/>
</objects>
</document>
2 changes: 1 addition & 1 deletion AutoPkgr/LGAppDelegate.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

@class LGConfigurationWindowController;

@interface LGAppDelegate : NSObject <NSApplicationDelegate,LGProgressDelegate>
@interface LGAppDelegate : NSObject <NSApplicationDelegate, LGProgressDelegate>
{
@private
LGConfigurationWindowController *configurationWindowController;
Expand Down
15 changes: 9 additions & 6 deletions AutoPkgr/LGAppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ - (void)applicationDidFinishLaunching:(NSNotification *)aNotification
{
LGDefaults *defaults = [LGDefaults new];

// set self as the delegate for the time so the menu item is updated
// Set self as the delegate for the time so the menu item is updated
// during timed runs.
[[LGAutoPkgSchedule sharedTimer] setProgressDelegate:self];

Expand Down Expand Up @@ -80,7 +80,7 @@ - (void)checkNowFromMenu:(id)sender
progress:^(NSString *message, double taskProgress) {
[self updateProgress:message progress:taskProgress];
}
reply:^(NSDictionary *report,NSError *error) {
reply:^(NSDictionary *report, NSError *error) {
[self stopProgress:error];
LGEmailer *emailer = [LGEmailer new];
[emailer sendEmailForReport:report error:error];
Expand Down Expand Up @@ -120,28 +120,31 @@ - (NSApplicationTerminateReply)applicationShouldTerminate:(NSApplication *)sende
}

# pragma mark - Progress Protocol
-(void)startProgressWithMessage:(NSString *)message{
- (void)startProgressWithMessage:(NSString *)message
{
__block NSMenuItem *item = [self.statusMenu itemAtIndex:0];
[item setAction:nil];
[item setTitle:message];
}

-(void)stopProgress:(NSError *)error{
- (void)stopProgress:(NSError *)error
{
__block NSMenuItem *item = [self.statusMenu itemAtIndex:0];
[[NSOperationQueue mainQueue] addOperationWithBlock:^{
[item setTitle:@"Check Now"];
[item setAction:@selector(checkNowFromMenu:)];
}];
}

-(void)updateProgress:(NSString *)message progress:(double)progress{
- (void)updateProgress:(NSString *)message progress:(double)progress
{
__block NSMenuItem *item = [self.statusMenu itemAtIndex:0];
if (message.length < 50) {
[[NSOperationQueue mainQueue] addOperationWithBlock:^{
[item setTitle:message];
}];
}
NSLog(@"%@",message);
NSLog(@"%@", message);
}

@end
12 changes: 6 additions & 6 deletions AutoPkgr/LGApplications.m
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ - (id)tableView:(NSTableView *)tableView objectValueForTableColumn:(NSTableColum

- (void)tableView:(NSTableView *)tableView setObjectValue:(id)object forTableColumn:(NSTableColumn *)tableColumn row:(NSInteger)row
{
if([[tableColumn identifier] isEqualToString:@"appCheckbox"]) {
if ([[tableColumn identifier] isEqualToString:@"appCheckbox"]) {
NSMutableArray *workingArray = [NSMutableArray arrayWithArray:activeApps];
if ([object isEqual:@YES]) {
[workingArray addObject:[searchedApps objectAtIndex:row]];
Expand All @@ -127,7 +127,7 @@ - (void)tableView:(NSTableView *)tableView setObjectValue:(id)object forTableCol
if (index != NSNotFound) {
[workingArray removeObjectAtIndex:index];
} else {
NSLog(@"Cannot find item %@ in workingArray", [searchedApps objectAtIndex:row]);
NSLog(@"Cannot find item %@ in workingArray.", [searchedApps objectAtIndex:row]);
}
}
activeApps = [NSArray arrayWithArray:workingArray];
Expand Down Expand Up @@ -161,7 +161,7 @@ - (void)writeRecipeList

NSString *autoPkgrSupportDirectory = [self getAppSupportDirectory];
if ([autoPkgrSupportDirectory isEqual:@""]) {
NSLog(@"Could not write recipe_list.txt");
NSLog(@"Could not write recipe_list.txt.");
return;
}

Expand All @@ -184,14 +184,14 @@ - (void)writeRecipeList
[recipe_list writeToFile:recipeListFile atomically:YES encoding:NSUTF8StringEncoding error:&error];

if (error) {
NSLog(@"Error while writing %@", recipeListFile);
NSLog(@"Error while writing %@.", recipeListFile);
}
}

- (void)executeAppSearch:(id)sender
{
[applicationTableView beginUpdates];
[applicationTableView removeRowsAtIndexes:[NSIndexSet indexSetWithIndexesInRange:NSMakeRange(0,searchedApps.count)] withAnimation:NSTableViewAnimationEffectNone];
[applicationTableView removeRowsAtIndexes:[NSIndexSet indexSetWithIndexesInRange:NSMakeRange(0, searchedApps.count)] withAnimation:NSTableViewAnimationEffectNone];

if ([[_appSearch stringValue] isEqualToString:@""]) {
searchedApps = apps;
Expand All @@ -209,7 +209,7 @@ - (void)executeAppSearch:(id)sender
searchedApps = [NSArray arrayWithArray:workingSearchArray];
}

[applicationTableView insertRowsAtIndexes:[NSIndexSet indexSetWithIndexesInRange:NSMakeRange(0,searchedApps.count)] withAnimation:NSTableViewAnimationEffectNone];
[applicationTableView insertRowsAtIndexes:[NSIndexSet indexSetWithIndexesInRange:NSMakeRange(0, searchedApps.count)] withAnimation:NSTableViewAnimationEffectNone];

[applicationTableView endUpdates];
}
Expand Down
5 changes: 3 additions & 2 deletions AutoPkgr/LGAutoPkgSchedule.m
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ - (void)runAutoPkg

LGDefaults *defaults = [[LGDefaults alloc] init];
if (defaults.checkForNewVersionsOfAppsAutomaticallyEnabled) {
NSLog(@"Beginning scheduled run of AutoPkg");
NSLog(@"Beginning scheduled run of AutoPkg.");
[_progressDelegate startProgressWithMessage:@"Starting scheduled run..."];
NSString *recipeList = [LGApplications recipeList];

Expand All @@ -73,7 +73,7 @@ - (void)runAutoPkg
[_progressDelegate updateProgress:message progress:taskProgress];
}
reply:^(NSDictionary *report, NSError *error) {
NSLog(@"Scheduled run of AutoPkg complete");
NSLog(@"Scheduled run of AutoPkg complete.");
[_progressDelegate stopProgress:error];
LGEmailer *emailer = [LGEmailer new];
[emailer sendEmailForReport:report error:error];
Expand All @@ -82,4 +82,5 @@ - (void)runAutoPkg
[self stopTimer];
}
}

@end
Loading

0 comments on commit f3394fc

Please sign in to comment.