fix: icons for setup and uninstall

This commit is contained in:
Prateek Sunal 2024-03-28 21:24:10 +05:30
parent c7de109494
commit d4ca574f1f
10 changed files with 2153 additions and 2150 deletions

View file

Before

Width:  |  Height:  |  Size: 8.1 KiB

After

Width:  |  Height:  |  Size: 8.1 KiB

View file

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

View file

@ -1,6 +1,6 @@
flutter_icons:
android: "launcher_icon"
image_path: "assets/icon-light.png"
adaptive_icon_foreground: "assets/icon-light-adaptive-fg.png"
adaptive_icon_background: "#ffffff"
flutter_icons:
android: "launcher_icon"
image_path: "assets/generation-icons/icon-light.png"
adaptive_icon_foreground: "assets/generation-icons/icon-light-adaptive-fg.png"
adaptive_icon_background: "#ffffff"

View file

@ -1,184 +1,185 @@
import 'dart:async';
import 'dart:io';
import 'package:adaptive_theme/adaptive_theme.dart';
import "package:ente_auth/app/view/app.dart";
import 'package:ente_auth/core/configuration.dart';
import 'package:ente_auth/core/constants.dart';
import 'package:ente_auth/core/logging/super_logging.dart';
import 'package:ente_auth/core/network.dart';
import 'package:ente_auth/ente_theme_data.dart';
import 'package:ente_auth/locale.dart';
import 'package:ente_auth/services/authenticator_service.dart';
import 'package:ente_auth/services/billing_service.dart';
import 'package:ente_auth/services/notification_service.dart';
import 'package:ente_auth/services/preference_service.dart';
import 'package:ente_auth/services/update_service.dart';
import 'package:ente_auth/services/user_remote_flag_service.dart';
import 'package:ente_auth/services/user_service.dart';
import 'package:ente_auth/services/window_listener_service.dart';
import 'package:ente_auth/store/code_store.dart';
import 'package:ente_auth/ui/tools/app_lock.dart';
import 'package:ente_auth/ui/tools/lock_screen.dart';
import 'package:ente_auth/ui/utils/icon_utils.dart';
import 'package:ente_auth/utils/platform_util.dart';
import 'package:ente_auth/utils/window_protocol_handler.dart';
import 'package:ente_crypto_dart/ente_crypto_dart.dart';
import 'package:flutter/foundation.dart';
import "package:flutter/material.dart";
import 'package:flutter/scheduler.dart';
import 'package:flutter_displaymode/flutter_displaymode.dart';
import 'package:logging/logging.dart';
import 'package:path_provider/path_provider.dart';
import 'package:privacy_screen/privacy_screen.dart';
import 'package:system_tray/system_tray.dart';
import 'package:window_manager/window_manager.dart';
final _logger = Logger("main");
Future<void> initSystemTray() async {
String path =
Platform.isWindows ? 'assets/icon-light.ico' : 'assets/icon-light.png';
final AppWindow appWindow = AppWindow();
final SystemTray systemTray = SystemTray();
// We first init the systray menu
await systemTray.initSystemTray(
title: "",
iconPath: path,
);
// create context menu
final show = MenuItem(label: 'Show', onClicked: () => appWindow.show());
final hide = MenuItem(label: 'Hide', onClicked: () => appWindow.hide());
final exit = MenuItem(label: 'Exit', onClicked: () => appWindow.close());
// set context menu
await systemTray.setContextMenu([show, hide, exit]);
const kSystemTrayEventClick = 'leftMouseDown';
const kSystemTrayEventRightClick = 'rightMouseDown';
// // handle system tray event
systemTray.registerSystemTrayEventHandler((eventName) {
if (eventName == kSystemTrayEventClick) {
Platform.isWindows ? appWindow.show() : systemTray.popUpContextMenu();
} else if (eventName == kSystemTrayEventRightClick) {
Platform.isWindows ? systemTray.popUpContextMenu() : appWindow.show();
}
});
}
void main() async {
WidgetsFlutterBinding.ensureInitialized();
initSystemTray().ignore();
if (PlatformUtil.isDesktop()) {
await windowManager.ensureInitialized();
await WindowListenerService.instance.init();
WindowOptions windowOptions = WindowOptions(
size: WindowListenerService.instance.getWindowSize(),
);
await windowManager.waitUntilReadyToShow(windowOptions, () async {
await windowManager.show();
await windowManager.focus();
});
}
await _runInForeground();
await _setupPrivacyScreen();
if (Platform.isAndroid) {
FlutterDisplayMode.setHighRefreshRate().ignore();
}
}
Future<void> _runInForeground() async {
final savedThemeMode = _themeMode(await AdaptiveTheme.getThemeMode());
return await _runWithLogs(() async {
_logger.info("Starting app in foreground");
await _init(false, via: 'mainMethod');
final Locale locale = await getLocale();
unawaited(UpdateService.instance.showUpdateNotification());
runApp(
AppLock(
builder: (args) => App(locale: locale),
lockScreen: const LockScreen(),
enabled: Configuration.instance.shouldShowLockScreen(),
locale: locale,
lightTheme: lightThemeData,
darkTheme: darkThemeData,
savedThemeMode: savedThemeMode,
),
);
});
}
ThemeMode _themeMode(AdaptiveThemeMode? savedThemeMode) {
if (savedThemeMode == null) return ThemeMode.system;
if (savedThemeMode.isLight) return ThemeMode.light;
if (savedThemeMode.isDark) return ThemeMode.dark;
return ThemeMode.system;
}
Future _runWithLogs(Function() function, {String prefix = ""}) async {
String dir = "";
try {
dir = "${(await getApplicationSupportDirectory()).path}/logs";
} catch (_) {}
await SuperLogging.main(
LogConfig(
body: function,
logDirPath: dir,
maxLogFiles: 5,
sentryDsn: sentryDSN,
enableInDebugMode: true,
prefix: prefix,
),
);
}
void _registerWindowsProtocol() {
const kWindowsScheme = 'ente';
// Register our protocol only on Windows platform
if (!kIsWeb && Platform.isWindows) {
WindowsProtocolHandler()
.register(kWindowsScheme, executable: null, arguments: null);
}
}
Future<void> _init(bool bool, {String? via}) async {
_registerWindowsProtocol();
await initCryptoUtil();
await PreferenceService.instance.init();
await CodeStore.instance.init();
await Configuration.instance.init();
await Network.instance.init();
await UserService.instance.init();
await UserRemoteFlagService.instance.init();
await AuthenticatorService.instance.init();
await BillingService.instance.init();
await NotificationService.instance.init();
await UpdateService.instance.init();
await IconUtils.instance.init();
}
Future<void> _setupPrivacyScreen() async {
if (!PlatformUtil.isMobile()) return;
final brightness =
SchedulerBinding.instance.platformDispatcher.platformBrightness;
bool isInDarkMode = brightness == Brightness.dark;
await PrivacyScreen.instance.enable(
iosOptions: const PrivacyIosOptions(
enablePrivacy: true,
privacyImageName: "LaunchImage",
lockTrigger: IosLockTrigger.didEnterBackground,
),
androidOptions: const PrivacyAndroidOptions(
enableSecure: true,
),
backgroundColor: isInDarkMode ? Colors.black : Colors.white,
blurEffect:
isInDarkMode ? PrivacyBlurEffect.dark : PrivacyBlurEffect.extraLight,
);
}
import 'dart:async';
import 'dart:io';
import 'package:adaptive_theme/adaptive_theme.dart';
import "package:ente_auth/app/view/app.dart";
import 'package:ente_auth/core/configuration.dart';
import 'package:ente_auth/core/constants.dart';
import 'package:ente_auth/core/logging/super_logging.dart';
import 'package:ente_auth/core/network.dart';
import 'package:ente_auth/ente_theme_data.dart';
import 'package:ente_auth/locale.dart';
import 'package:ente_auth/services/authenticator_service.dart';
import 'package:ente_auth/services/billing_service.dart';
import 'package:ente_auth/services/notification_service.dart';
import 'package:ente_auth/services/preference_service.dart';
import 'package:ente_auth/services/update_service.dart';
import 'package:ente_auth/services/user_remote_flag_service.dart';
import 'package:ente_auth/services/user_service.dart';
import 'package:ente_auth/services/window_listener_service.dart';
import 'package:ente_auth/store/code_store.dart';
import 'package:ente_auth/ui/tools/app_lock.dart';
import 'package:ente_auth/ui/tools/lock_screen.dart';
import 'package:ente_auth/ui/utils/icon_utils.dart';
import 'package:ente_auth/utils/platform_util.dart';
import 'package:ente_auth/utils/window_protocol_handler.dart';
import 'package:ente_crypto_dart/ente_crypto_dart.dart';
import 'package:flutter/foundation.dart';
import "package:flutter/material.dart";
import 'package:flutter/scheduler.dart';
import 'package:flutter_displaymode/flutter_displaymode.dart';
import 'package:logging/logging.dart';
import 'package:path_provider/path_provider.dart';
import 'package:privacy_screen/privacy_screen.dart';
import 'package:system_tray/system_tray.dart';
import 'package:window_manager/window_manager.dart';
final _logger = Logger("main");
Future<void> initSystemTray() async {
String path = Platform.isWindows
? 'assets/icon/auth-icon.ico'
: 'assets/icon/auth-icon.png';
final AppWindow appWindow = AppWindow();
final SystemTray systemTray = SystemTray();
// We first init the systray menu
await systemTray.initSystemTray(
title: "",
iconPath: path,
);
// create context menu
final show = MenuItem(label: 'Show', onClicked: () => appWindow.show());
final hide = MenuItem(label: 'Hide', onClicked: () => appWindow.hide());
final exit = MenuItem(label: 'Exit', onClicked: () => windowManager.close());
// set context menu
await systemTray.setContextMenu([show, hide, exit]);
const kSystemTrayEventClick = 'leftMouseDown';
const kSystemTrayEventRightClick = 'rightMouseDown';
// // handle system tray event
systemTray.registerSystemTrayEventHandler((eventName) {
if (eventName == kSystemTrayEventClick) {
Platform.isWindows ? appWindow.show() : systemTray.popUpContextMenu();
} else if (eventName == kSystemTrayEventRightClick) {
Platform.isWindows ? systemTray.popUpContextMenu() : appWindow.show();
}
});
}
void main() async {
WidgetsFlutterBinding.ensureInitialized();
initSystemTray().ignore();
if (PlatformUtil.isDesktop()) {
await windowManager.ensureInitialized();
await WindowListenerService.instance.init();
WindowOptions windowOptions = WindowOptions(
size: WindowListenerService.instance.getWindowSize(),
);
await windowManager.waitUntilReadyToShow(windowOptions, () async {
await windowManager.show();
await windowManager.focus();
});
}
await _runInForeground();
await _setupPrivacyScreen();
if (Platform.isAndroid) {
FlutterDisplayMode.setHighRefreshRate().ignore();
}
}
Future<void> _runInForeground() async {
final savedThemeMode = _themeMode(await AdaptiveTheme.getThemeMode());
return await _runWithLogs(() async {
_logger.info("Starting app in foreground");
await _init(false, via: 'mainMethod');
final Locale locale = await getLocale();
unawaited(UpdateService.instance.showUpdateNotification());
runApp(
AppLock(
builder: (args) => App(locale: locale),
lockScreen: const LockScreen(),
enabled: Configuration.instance.shouldShowLockScreen(),
locale: locale,
lightTheme: lightThemeData,
darkTheme: darkThemeData,
savedThemeMode: savedThemeMode,
),
);
});
}
ThemeMode _themeMode(AdaptiveThemeMode? savedThemeMode) {
if (savedThemeMode == null) return ThemeMode.system;
if (savedThemeMode.isLight) return ThemeMode.light;
if (savedThemeMode.isDark) return ThemeMode.dark;
return ThemeMode.system;
}
Future _runWithLogs(Function() function, {String prefix = ""}) async {
String dir = "";
try {
dir = "${(await getApplicationSupportDirectory()).path}/logs";
} catch (_) {}
await SuperLogging.main(
LogConfig(
body: function,
logDirPath: dir,
maxLogFiles: 5,
sentryDsn: sentryDSN,
enableInDebugMode: true,
prefix: prefix,
),
);
}
void _registerWindowsProtocol() {
const kWindowsScheme = 'ente';
// Register our protocol only on Windows platform
if (!kIsWeb && Platform.isWindows) {
WindowsProtocolHandler()
.register(kWindowsScheme, executable: null, arguments: null);
}
}
Future<void> _init(bool bool, {String? via}) async {
_registerWindowsProtocol();
await initCryptoUtil();
await PreferenceService.instance.init();
await CodeStore.instance.init();
await Configuration.instance.init();
await Network.instance.init();
await UserService.instance.init();
await UserRemoteFlagService.instance.init();
await AuthenticatorService.instance.init();
await BillingService.instance.init();
await NotificationService.instance.init();
await UpdateService.instance.init();
await IconUtils.instance.init();
}
Future<void> _setupPrivacyScreen() async {
if (!PlatformUtil.isMobile()) return;
final brightness =
SchedulerBinding.instance.platformDispatcher.platformBrightness;
bool isInDarkMode = brightness == Brightness.dark;
await PrivacyScreen.instance.enable(
iosOptions: const PrivacyIosOptions(
enablePrivacy: true,
privacyImageName: "LaunchImage",
lockTrigger: IosLockTrigger.didEnterBackground,
),
androidOptions: const PrivacyAndroidOptions(
enableSecure: true,
),
backgroundColor: isInDarkMode ? Colors.black : Colors.white,
blurEffect:
isInDarkMode ? PrivacyBlurEffect.dark : PrivacyBlurEffect.extraLight,
);
}

File diff suppressed because it is too large Load diff

View file

@ -1,157 +1,158 @@
name: ente_auth
description: ente two-factor authenticator
version: 2.0.46+246
publish_to: none
environment:
sdk: ">=3.0.0 <4.0.0"
dependencies:
adaptive_theme: ^3.1.0 # done
app_links: ^3.5.0
archive: ^3.3.7
base32: ^2.1.3
bip39: ^1.0.6 #done
bloc: ^8.1.2
clipboard: ^0.1.3
collection: # dart
confetti: ^0.7.0
connectivity_plus: ^5.0.2
convert: ^3.1.1
desktop_webview_window:
git:
url: https://github.com/MixinNetwork/flutter-plugins
path: packages/desktop_webview_window
device_info_plus: ^9.1.1
dio: ^5.4.0
dotted_border: ^2.0.0+2
email_validator: ^2.0.1
ente_crypto_dart:
git:
url: https://github.com/ente-io/ente_crypto_dart.git
event_bus: ^2.0.0
expandable: ^5.0.1
expansion_tile_card: ^3.0.0
ffi: ^2.1.0
file_picker: ^6.1.1
# https://github.com/incrediblezayed/file_saver/issues/86
file_saver: ^0.2.11
fixnum: ^1.1.0
fk_user_agent: ^2.1.0
flutter:
sdk: flutter
flutter_bloc: ^8.0.1
flutter_displaymode: ^0.6.0
flutter_email_sender: ^6.0.2
flutter_inappwebview: ^6.0.0
flutter_launcher_icons: ^0.13.1
flutter_local_authentication:
git:
url: https://github.com/eaceto/flutter_local_authentication
ref: 1ac346a04592a05fd75acccf2e01fa3c7e955d96
flutter_local_notifications: ^16.3.1+1
flutter_localizations:
sdk: flutter
flutter_native_splash: ^2.2.13
flutter_secure_storage: ^9.0.0
flutter_slidable: ^3.0.1
flutter_speed_dial: ^7.0.0
flutter_staggered_grid_view: ^0.7.0
flutter_svg: ^2.0.5
fluttertoast: ^8.1.1
google_nav_bar: ^5.0.5 #supported
http: ^1.1.0
intl: ^0.18.0
json_annotation: ^4.5.0
local_auth: ^2.1.7
local_auth_android: ^1.0.31
local_auth_ios: ^1.1.3
logging: ^1.0.1
modal_bottom_sheet: ^3.0.0-pre
move_to_background: ^1.0.2
otp: ^3.1.1
package_info_plus: ^4.1.0
password_strength: ^0.2.0
path: ^1.8.3
path_provider: ^2.0.11
pinput: ^3.0.1
pointycastle: ^3.7.3
privacy_screen: ^0.0.6
protobuf: ^3.0.0
qr_code_scanner: ^1.0.1
qr_flutter: ^4.1.0
sentry: ^7.9.0
sentry_flutter: ^7.9.0
share_plus: ^7.2.1
shared_preferences: ^2.0.5
sqflite:
git:
url: https://github.com/tekartik/sqflite
path: sqflite
sqflite_common_ffi: ^2.3.0+4
sqlite3: ^2.1.0
sqlite3_flutter_libs: ^0.5.19+1
step_progress_indicator: ^1.0.2
styled_text: ^8.1.0
system_tray: ^0.1.1
tuple: ^2.0.0
url_launcher: ^6.1.5
uuid: ^4.2.2
win32: ^5.1.1
window_manager: ^0.3.8
dependency_overrides:
flutter_secure_storage_linux:
git:
url: https://github.com/prateekmedia/flutter_secure_storage.git
ref: patch-1
path: flutter_secure_storage_linux
dev_dependencies:
build_runner: ^2.1.11
flutter_test:
sdk: flutter
json_serializable: ^6.2.0
lints: ^3.0.0
mocktail: ^1.0.3
# The following section is specific to Flutter.
flutter:
uses-material-design: true
generate: true
# https://docs:flutter:dev/development/ui/assets-and-images:
assets:
- assets/
- assets/simple-icons/icons/
- assets/simple-icons/_data/
- assets/custom-icons/icons/
- assets/custom-icons/_data/
fonts:
- family: Inter
fonts:
- asset: fonts/Inter-Regular.ttf
- asset: fonts/Inter-Medium.ttf
- asset: fonts/Inter-Light.ttf
- asset: fonts/Inter-SemiBold.ttf
- asset: fonts/Inter-Bold.ttf
- family: Montserrat
fonts:
- asset: fonts/Montserrat-Bold.ttf
flutter_icons:
android: "launcher_icon"
adaptive_icon_foreground: "assets/icon-light-adaptive-fg.png"
adaptive_icon_background: "#ffffff"
ios: true
image_path: "assets/icon-light.png"
remove_alpha_ios: true
flutter_native_splash:
color: "#ffffff"
color_dark: "#000000"
image: assets/splash-screen-light.png
image_dark: assets/splash-screen-dark.png
android_fullscreen: true
android_gravity: center
ios_content_mode: center
name: ente_auth
description: ente two-factor authenticator
version: 2.0.46+246
publish_to: none
environment:
sdk: ">=3.0.0 <4.0.0"
dependencies:
adaptive_theme: ^3.1.0 # done
app_links: ^3.5.0
archive: ^3.3.7
base32: ^2.1.3
bip39: ^1.0.6 #done
bloc: ^8.1.2
clipboard: ^0.1.3
collection: # dart
confetti: ^0.7.0
connectivity_plus: ^5.0.2
convert: ^3.1.1
desktop_webview_window:
git:
url: https://github.com/MixinNetwork/flutter-plugins
path: packages/desktop_webview_window
device_info_plus: ^9.1.1
dio: ^5.4.0
dotted_border: ^2.0.0+2
email_validator: ^2.0.1
ente_crypto_dart:
git:
url: https://github.com/ente-io/ente_crypto_dart.git
event_bus: ^2.0.0
expandable: ^5.0.1
expansion_tile_card: ^3.0.0
ffi: ^2.1.0
file_picker: ^6.1.1
# https://github.com/incrediblezayed/file_saver/issues/86
file_saver: ^0.2.11
fixnum: ^1.1.0
fk_user_agent: ^2.1.0
flutter:
sdk: flutter
flutter_bloc: ^8.0.1
flutter_displaymode: ^0.6.0
flutter_email_sender: ^6.0.2
flutter_inappwebview: ^6.0.0
flutter_launcher_icons: ^0.13.1
flutter_local_authentication:
git:
url: https://github.com/eaceto/flutter_local_authentication
ref: 1ac346a04592a05fd75acccf2e01fa3c7e955d96
flutter_local_notifications: ^16.3.1+1
flutter_localizations:
sdk: flutter
flutter_native_splash: ^2.2.13
flutter_secure_storage: ^9.0.0
flutter_slidable: ^3.0.1
flutter_speed_dial: ^7.0.0
flutter_staggered_grid_view: ^0.7.0
flutter_svg: ^2.0.5
fluttertoast: ^8.1.1
google_nav_bar: ^5.0.5 #supported
http: ^1.1.0
intl: ^0.18.0
json_annotation: ^4.5.0
local_auth: ^2.1.7
local_auth_android: ^1.0.31
local_auth_ios: ^1.1.3
logging: ^1.0.1
modal_bottom_sheet: ^3.0.0-pre
move_to_background: ^1.0.2
otp: ^3.1.1
package_info_plus: ^4.1.0
password_strength: ^0.2.0
path: ^1.8.3
path_provider: ^2.0.11
pinput: ^3.0.1
pointycastle: ^3.7.3
privacy_screen: ^0.0.6
protobuf: ^3.0.0
qr_code_scanner: ^1.0.1
qr_flutter: ^4.1.0
sentry: ^7.9.0
sentry_flutter: ^7.9.0
share_plus: ^7.2.1
shared_preferences: ^2.0.5
sqflite:
git:
url: https://github.com/tekartik/sqflite
path: sqflite
sqflite_common_ffi: ^2.3.0+4
sqlite3: ^2.1.0
sqlite3_flutter_libs: ^0.5.19+1
step_progress_indicator: ^1.0.2
styled_text: ^8.1.0
system_tray: ^0.1.1
tuple: ^2.0.0
url_launcher: ^6.1.5
uuid: ^4.2.2
win32: ^5.1.1
window_manager: ^0.3.8
dependency_overrides:
flutter_secure_storage_linux:
git:
url: https://github.com/prateekmedia/flutter_secure_storage.git
ref: patch-1
path: flutter_secure_storage_linux
dev_dependencies:
build_runner: ^2.1.11
flutter_test:
sdk: flutter
json_serializable: ^6.2.0
lints: ^3.0.0
mocktail: ^1.0.3
# The following section is specific to Flutter.
flutter:
uses-material-design: true
generate: true
# https://docs:flutter:dev/development/ui/assets-and-images:
assets:
- assets/
- assets/icon/
- assets/simple-icons/icons/
- assets/simple-icons/_data/
- assets/custom-icons/icons/
- assets/custom-icons/_data/
fonts:
- family: Inter
fonts:
- asset: fonts/Inter-Regular.ttf
- asset: fonts/Inter-Medium.ttf
- asset: fonts/Inter-Light.ttf
- asset: fonts/Inter-SemiBold.ttf
- asset: fonts/Inter-Bold.ttf
- family: Montserrat
fonts:
- asset: fonts/Montserrat-Bold.ttf
flutter_icons:
android: "launcher_icon"
adaptive_icon_foreground: "assets/generation-icons/icon-light-adaptive-fg.png"
adaptive_icon_background: "#ffffff"
ios: true
image_path: "assets/generation-icons/icon-light.png"
remove_alpha_ios: true
flutter_native_splash:
color: "#ffffff"
color_dark: "#000000"
image: assets/splash-screen-light.png
image_dark: assets/splash-screen-dark.png
android_fullscreen: true
android_gravity: center
ios_content_mode: center

View file

@ -1,62 +1,62 @@
[Setup]
AppId={{APP_ID}}
AppVersion={{APP_VERSION}}
AppName={{DISPLAY_NAME}}
AppPublisher={{PUBLISHER_NAME}}
AppPublisherURL={{PUBLISHER_URL}}
AppSupportURL={{PUBLISHER_URL}}
AppUpdatesURL={{PUBLISHER_URL}}
DefaultDirName={{INSTALL_DIR_NAME}}
DisableProgramGroupPage=yes
OutputDir=.
OutputBaseFilename={{OUTPUT_BASE_FILENAME}}
Compression=lzma
SolidCompression=yes
SetupIconFile={{SETUP_ICON_FILE}}
WizardStyle=modern
PrivilegesRequired={{PRIVILEGES_REQUIRED}}
ArchitecturesAllowed=x64
ArchitecturesInstallIn64BitMode=x64
[Languages]
{% for locale in LOCALES %}
{% if locale == 'en' %}Name: "english"; MessagesFile: "compiler:Default.isl"{% endif %}
{% if locale == 'hy' %}Name: "armenian"; MessagesFile: "compiler:Languages\\Armenian.isl"{% endif %}
{% if locale == 'bg' %}Name: "bulgarian"; MessagesFile: "compiler:Languages\\Bulgarian.isl"{% endif %}
{% if locale == 'ca' %}Name: "catalan"; MessagesFile: "compiler:Languages\\Catalan.isl"{% endif %}
{% if locale == 'zh' %}Name: "chinesesimplified"; MessagesFile: "compiler:Languages\\ChineseSimplified.isl"{% endif %}
{% if locale == 'co' %}Name: "corsican"; MessagesFile: "compiler:Languages\\Corsican.isl"{% endif %}
{% if locale == 'cs' %}Name: "czech"; MessagesFile: "compiler:Languages\\Czech.isl"{% endif %}
{% if locale == 'da' %}Name: "danish"; MessagesFile: "compiler:Languages\\Danish.isl"{% endif %}
{% if locale == 'nl' %}Name: "dutch"; MessagesFile: "compiler:Languages\\Dutch.isl"{% endif %}
{% if locale == 'fi' %}Name: "finnish"; MessagesFile: "compiler:Languages\\Finnish.isl"{% endif %}
{% if locale == 'fr' %}Name: "french"; MessagesFile: "compiler:Languages\\French.isl"{% endif %}
{% if locale == 'de' %}Name: "german"; MessagesFile: "compiler:Languages\\German.isl"{% endif %}
{% if locale == 'he' %}Name: "hebrew"; MessagesFile: "compiler:Languages\\Hebrew.isl"{% endif %}
{% if locale == 'is' %}Name: "icelandic"; MessagesFile: "compiler:Languages\\Icelandic.isl"{% endif %}
{% if locale == 'it' %}Name: "italian"; MessagesFile: "compiler:Languages\\Italian.isl"{% endif %}
{% if locale == 'ja' %}Name: "japanese"; MessagesFile: "compiler:Languages\\Japanese.isl"{% endif %}
{% if locale == 'no' %}Name: "norwegian"; MessagesFile: "compiler:Languages\\Norwegian.isl"{% endif %}
{% if locale == 'pl' %}Name: "polish"; MessagesFile: "compiler:Languages\\Polish.isl"{% endif %}
{% if locale == 'pt' %}Name: "portuguese"; MessagesFile: "compiler:Languages\\Portuguese.isl"{% endif %}
{% if locale == 'ru' %}Name: "russian"; MessagesFile: "compiler:Languages\\Russian.isl"{% endif %}
{% if locale == 'sk' %}Name: "slovak"; MessagesFile: "compiler:Languages\\Slovak.isl"{% endif %}
{% if locale == 'sl' %}Name: "slovenian"; MessagesFile: "compiler:Languages\\Slovenian.isl"{% endif %}
{% if locale == 'es' %}Name: "spanish"; MessagesFile: "compiler:Languages\\Spanish.isl"{% endif %}
{% if locale == 'tr' %}Name: "turkish"; MessagesFile: "compiler:Languages\\Turkish.isl"{% endif %}
{% if locale == 'uk' %}Name: "ukrainian"; MessagesFile: "compiler:Languages\\Ukrainian.isl"{% endif %}
{% endfor %}
[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: {% if CREATE_DESKTOP_ICON != true %}unchecked{% else %}checkedonce{% endif %}
Name: "launchAtStartup"; Description: "{cm:AutoStartProgram,{{DISPLAY_NAME}}}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: {% if LAUNCH_AT_STARTUP != true %}unchecked{% else %}checkedonce{% endif %}
[Files]
Source: "{{SOURCE_DIR}}\\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs
; NOTE: Don't use "Flags: ignoreversion" on any shared system files
[Icons]
Name: "{autoprograms}\\{{DISPLAY_NAME}}"; Filename: "{app}\\{{EXECUTABLE_NAME}}"
Name: "{autodesktop}\\{{DISPLAY_NAME}}"; Filename: "{app}\\{{EXECUTABLE_NAME}}"; Tasks: desktopicon
Name: "{userstartup}\\{{DISPLAY_NAME}}"; Filename: "{app}\\{{EXECUTABLE_NAME}}"; WorkingDir: "{app}"; Tasks: launchAtStartup
[Run]
Filename: "{app}\\{{EXECUTABLE_NAME}}"; Description: "{cm:LaunchProgram,{{DISPLAY_NAME}}}"; Flags: {% if PRIVILEGES_REQUIRED == 'admin' %}runascurrentuser{% endif %} nowait postinstall skipifsilent
[Setup]
AppId={{APP_ID}}
AppVersion={{APP_VERSION}}
AppName={{DISPLAY_NAME}}
AppPublisher={{PUBLISHER_NAME}}
AppPublisherURL={{PUBLISHER_URL}}
AppSupportURL={{PUBLISHER_URL}}
AppUpdatesURL={{PUBLISHER_URL}}
DefaultDirName={{INSTALL_DIR_NAME}}
DisableProgramGroupPage=yes
OutputDir=.
OutputBaseFilename={{OUTPUT_BASE_FILENAME}}
Compression=lzma
SolidCompression=yes
SetupIconFile={{SETUP_ICON_FILE}}
WizardStyle=modern
PrivilegesRequired={{PRIVILEGES_REQUIRED}}
ArchitecturesAllowed=x64
ArchitecturesInstallIn64BitMode=x64
[Languages]
{% for locale in LOCALES %}
{% if locale == 'en' %}Name: "english"; MessagesFile: "compiler:Default.isl"{% endif %}
{% if locale == 'hy' %}Name: "armenian"; MessagesFile: "compiler:Languages\\Armenian.isl"{% endif %}
{% if locale == 'bg' %}Name: "bulgarian"; MessagesFile: "compiler:Languages\\Bulgarian.isl"{% endif %}
{% if locale == 'ca' %}Name: "catalan"; MessagesFile: "compiler:Languages\\Catalan.isl"{% endif %}
{% if locale == 'zh' %}Name: "chinesesimplified"; MessagesFile: "compiler:Languages\\ChineseSimplified.isl"{% endif %}
{% if locale == 'co' %}Name: "corsican"; MessagesFile: "compiler:Languages\\Corsican.isl"{% endif %}
{% if locale == 'cs' %}Name: "czech"; MessagesFile: "compiler:Languages\\Czech.isl"{% endif %}
{% if locale == 'da' %}Name: "danish"; MessagesFile: "compiler:Languages\\Danish.isl"{% endif %}
{% if locale == 'nl' %}Name: "dutch"; MessagesFile: "compiler:Languages\\Dutch.isl"{% endif %}
{% if locale == 'fi' %}Name: "finnish"; MessagesFile: "compiler:Languages\\Finnish.isl"{% endif %}
{% if locale == 'fr' %}Name: "french"; MessagesFile: "compiler:Languages\\French.isl"{% endif %}
{% if locale == 'de' %}Name: "german"; MessagesFile: "compiler:Languages\\German.isl"{% endif %}
{% if locale == 'he' %}Name: "hebrew"; MessagesFile: "compiler:Languages\\Hebrew.isl"{% endif %}
{% if locale == 'is' %}Name: "icelandic"; MessagesFile: "compiler:Languages\\Icelandic.isl"{% endif %}
{% if locale == 'it' %}Name: "italian"; MessagesFile: "compiler:Languages\\Italian.isl"{% endif %}
{% if locale == 'ja' %}Name: "japanese"; MessagesFile: "compiler:Languages\\Japanese.isl"{% endif %}
{% if locale == 'no' %}Name: "norwegian"; MessagesFile: "compiler:Languages\\Norwegian.isl"{% endif %}
{% if locale == 'pl' %}Name: "polish"; MessagesFile: "compiler:Languages\\Polish.isl"{% endif %}
{% if locale == 'pt' %}Name: "portuguese"; MessagesFile: "compiler:Languages\\Portuguese.isl"{% endif %}
{% if locale == 'ru' %}Name: "russian"; MessagesFile: "compiler:Languages\\Russian.isl"{% endif %}
{% if locale == 'sk' %}Name: "slovak"; MessagesFile: "compiler:Languages\\Slovak.isl"{% endif %}
{% if locale == 'sl' %}Name: "slovenian"; MessagesFile: "compiler:Languages\\Slovenian.isl"{% endif %}
{% if locale == 'es' %}Name: "spanish"; MessagesFile: "compiler:Languages\\Spanish.isl"{% endif %}
{% if locale == 'tr' %}Name: "turkish"; MessagesFile: "compiler:Languages\\Turkish.isl"{% endif %}
{% if locale == 'uk' %}Name: "ukrainian"; MessagesFile: "compiler:Languages\\Ukrainian.isl"{% endif %}
{% endfor %}
[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: {% if CREATE_DESKTOP_ICON != true %}unchecked{% else %}checkedonce{% endif %}
Name: "launchAtStartup"; Description: "{cm:AutoStartProgram,{{DISPLAY_NAME}}}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: {% if LAUNCH_AT_STARTUP != true %}unchecked{% else %}checkedonce{% endif %}
[Files]
Source: "{{SOURCE_DIR}}\\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs
; NOTE: Don't use "Flags: ignoreversion" on any shared system files
[Icons]
Name: "{autoprograms}\\{{DISPLAY_NAME}}"; Filename: "{app}\\{{EXECUTABLE_NAME}}"
Name: "{autodesktop}\\{{DISPLAY_NAME}}"; Filename: "{app}\\{{EXECUTABLE_NAME}}"; Tasks: desktopicon
Name: "{userstartup}\\{{DISPLAY_NAME}}"; Filename: "{app}\\{{EXECUTABLE_NAME}}"; WorkingDir: "{app}"; Tasks: launchAtStartup
[Run]
Filename: "{app}\\{{EXECUTABLE_NAME}}"; Description: "{cm:LaunchProgram,{{DISPLAY_NAME}}}"; Flags: {% if PRIVILEGES_REQUIRED == 'admin' %}runascurrentuser{% endif %} nowait postinstall skipifsilent

View file

@ -1,9 +1,10 @@
app_id: 9E5F0C93-96A3-4DA9-AE52-1AA6339851FC
publisher: ente.io
publisher_url: https://github.com/ente-io/ente
display_name: ente Auth
create_desktop_icon: false
install_dir_name: "{pf}\\Ente Auth"
script_template: inno_setup.iss
locales:
- en
app_id: 9E5F0C93-96A3-4DA9-AE52-1AA6339851FC
publisher: ente.io
publisher_url: https://github.com/ente-io/ente
display_name: ente Auth
create_desktop_icon: false
install_dir_name: "{pf}\\Ente Auth"
setup_icon_file: ../../assets/icon/auth-icon.ico
script_template: inno_setup.iss
locales:
- en