diff --git a/SUConstants.h b/SUConstants.h index fc929f98..bc5f7a07 100644 --- a/SUConstants.h +++ b/SUConstants.h @@ -10,9 +10,22 @@ #ifndef SUCONSTANTS_H #define SUCONSTANTS_H +// ----------------------------------------------------------------------------- +// Preprocessor flags: +// ----------------------------------------------------------------------------- + +// Turn off DSA signature check (practically invites man-in-the-middle attacks): #define ENDANGER_USERS_WITH_INSECURE_UPDATES 1 + +// Sparkle usually doesn't allow downgrades as they're usually accidental, but +// if your app has a downgrade function or URL handler, turn this on: #define PERMIT_AUTOMATED_DOWNGRADES 1 +// If your app file on disk is named "MyApp 1.1b4", Sparkle usually updates it +// in place, giving you an app named 1.1b4 that is actually 1.2. Turn the +// following on to always reset the name back to "MyApp": +#define NORMALIZE_INSTALLED_APP_NAME 1 + // ----------------------------------------------------------------------------- // Notifications: // ----------------------------------------------------------------------------- diff --git a/SUHost.m b/SUHost.m index 3e4f65db..b8abdcab 100644 --- a/SUHost.m +++ b/SUHost.m @@ -48,7 +48,7 @@ - (NSString *)installationPath { -#if 1 +#if NORMALIZE_INSTALLED_APP_NAME return [[[bundle bundlePath] stringByDeletingLastPathComponent] stringByAppendingPathComponent: [NSString stringWithFormat: @"%@.%@", [bundle objectForInfoDictionaryKey:@"CFBundleName"], [[bundle bundlePath] pathExtension]]]; #else return [bundle bundlePath];