Permalink
Browse files

Don't spawn every minute of 3am

  • Loading branch information...
1 parent 5d9a96c commit e10c1dd1983a1769226061326089f61edfce2c9c @jdelStrother committed Jul 26, 2008
Showing with 4 additions and 2 deletions.
  1. +2 −0 AppController.m
  2. +2 −2 Nanofibre.plist
View
@@ -142,6 +142,8 @@ -(IBAction)installDaemon:(id)sender
NSString* dstAgentDir = [@"~/Library/LaunchAgents" stringByExpandingTildeInPath];
NSString* dstAgent = [dstAgentDir stringByAppendingPathComponent:@"Nanofibre.plist"];
[[NSFileManager defaultManager] createDirectoryAtPath:dstAgentDir attributes:nil];
+ if ([[NSFileManager defaultManager] fileExistsAtPath:dstAgent])
+ [[NSFileManager defaultManager] removeFileAtPath:dstAgent handler:nil];
[[NSFileManager defaultManager] copyPath:srcAgent toPath:dstAgent handler:nil];
[NSTask launchedTaskWithLaunchPath:@"/bin/launchctl" arguments:[NSArray arrayWithObjects:@"load", @"-w", dstAgent, nil]];
View
@@ -10,12 +10,12 @@
<array>
<string>/usr/local/bin/fibred</string>
</array>
- <key>ServiceDescription</key>
- <string>Launch Nanofibre to generate nano-sized playlists</string>
<key>StartCalendarInterval</key>
<dict>
<key>Hour</key>
<integer>3</integer>
+ <key>Minute</key>
+ <integer>15</integer>
</dict>
</dict>
</plist>

0 comments on commit e10c1dd

Please sign in to comment.