Move feed and downloads back to S3

This commit is contained in:
Christopher Snowhill 2022-01-15 19:04:26 -08:00
parent 8b7cd39576
commit 602facf31a
4 changed files with 7 additions and 6 deletions

View file

@ -456,7 +456,7 @@ void* kAppControllerContext = &kAppControllerContext;
NSNumber *fontSize = [NSNumber numberWithFloat:fFontSize]; NSNumber *fontSize = [NSNumber numberWithFloat:fFontSize];
[userDefaultsValuesDict setObject:fontSize forKey:@"fontSize"]; [userDefaultsValuesDict setObject:fontSize forKey:@"fontSize"];
NSString *feedURLdefault = @"https://f.losno.co/cog/mercury.xml"; NSString *feedURLdefault = @"https://cogcdn.cog.losno.co/mercury.xml";
[userDefaultsValuesDict setObject:feedURLdefault forKey:@"SUFeedURL"]; [userDefaultsValuesDict setObject:feedURLdefault forKey:@"SUFeedURL"];
[userDefaultsValuesDict setObject:@"clearAndPlay" forKey:@"openingFilesBehavior"]; [userDefaultsValuesDict setObject:@"clearAndPlay" forKey:@"openingFilesBehavior"];
@ -487,6 +487,7 @@ void* kAppControllerContext = &kAppControllerContext;
@"https://kode54.net/cog/stable.xml", @"https://kode54.net/cog/stable.xml",
@"https://kode54.net/cog/mercury.xml" @"https://kode54.net/cog/mercury.xml"
@"https://www.kode54.net/cog/mercury.xml", @"https://www.kode54.net/cog/mercury.xml",
@"https://f.losno.co/cog/mercury.xml",
nil]; nil];
NSString *feedURL = [[NSUserDefaults standardUserDefaults] stringForKey:@"SUFeedURL"]; NSString *feedURL = [[NSUserDefaults standardUserDefaults] stringForKey:@"SUFeedURL"];
if ([brokenFeedURLs containsObject:feedURL]) { if ([brokenFeedURLs containsObject:feedURL]) {

View file

@ -1044,7 +1044,7 @@
<key>NSRemindersUsageDescription</key> <key>NSRemindersUsageDescription</key>
<string>Cog has no use for your reminders. Why are you trying to access them with an audio player?</string> <string>Cog has no use for your reminders. Why are you trying to access them with an audio player?</string>
<key>SUFeedURL</key> <key>SUFeedURL</key>
<string>https://f.losno.co/cog/mercury.xml</string> <string>https://cogcdn.cog.losno.co/mercury.xml</string>
<key>SUPublicEDKey</key> <key>SUPublicEDKey</key>
<string>omxG7Rp0XK9/YEvKbVy7cd44eVAh1LJB6CmjQwjOJz4=</string> <string>omxG7Rp0XK9/YEvKbVy7cd44eVAh1LJB6CmjQwjOJz4=</string>
</dict> </dict>

View file

@ -29,7 +29,7 @@
[self addObject: [self addObject:
[NSDictionary dictionaryWithObjectsAndKeys: [NSDictionary dictionaryWithObjectsAndKeys:
NSLocalizedStringFromTableInBundle(@"losno.co wheneverly", nil, [NSBundle bundleForClass:[self class]], @"") , @"name", @"https://f.losno.co/cog/mercury.xml", @"url",nil]]; NSLocalizedStringFromTableInBundle(@"cog.losno.co wheneverly", nil, [NSBundle bundleForClass:[self class]], @"") , @"name", @"https://cogcdn.cog.losno.co/mercury.xml", @"url",nil]];
} }
@end @end

View file

@ -103,16 +103,16 @@ if 1 #appcast_revision < latest_revision
deltas = Dir.entries("#{site_dir}/#{feed}_builds").select { |f| f =~ /\A#{Regexp.escape(deltamask)}.+\.delta\z/ }.map { |f| File.join("#{site_dir}/#{feed}_builds", f) } deltas = Dir.entries("#{site_dir}/#{feed}_builds").select { |f| f =~ /\A#{Regexp.escape(deltamask)}.+\.delta\z/ }.map { |f| File.join("#{site_dir}/#{feed}_builds", f) }
#Upload them to S3 #Upload them to S3
%x[s3cmd put -P -m application/octet-stream #{deltas.shelljoin} '#{site_dir}/#{feed}_builds/#{filename}' s3://balde-losno-co/cog/] %x[s3cmd put -P -m application/octet-stream #{deltas.shelljoin} '#{site_dir}/#{feed}_builds/#{filename}' s3://cogcdn.cog.losno.co]
#Upload the changelog that Sparkle will display #Upload the changelog that Sparkle will display
%x[s3cmd put -P -m text/html '#{site_dir}/#{feed}_builds/#{filenamedesc}' s3://balde-losno-co/cog/] %x[s3cmd put -P -m text/html '#{site_dir}/#{feed}_builds/#{filenamedesc}' s3://cogcdn.cog.losno.co]
#Clean up #Clean up
%x[rm -rf '#{temp_path}/Cog.app'] %x[rm -rf '#{temp_path}/Cog.app']
#Upload to S3 #Upload to S3
%x[s3cmd put -P -m application/xml '#{site_dir}/#{feed}_builds/#{feed}.xml' s3://balde-losno-co/cog/] %x[s3cmd put -P -m application/xml '#{site_dir}/#{feed}_builds/#{feed}.xml' s3://cogcdn.cog.losno.co]
#Send web hook to update site #Send web hook to update site
update_uri = %x[security find-generic-password -w -a #{ENV['LOGNAME']} -s cogupdateurl] update_uri = %x[security find-generic-password -w -a #{ENV['LOGNAME']} -s cogupdateurl]