From b370131667080ac1a647706c7323549b043b4af7 Mon Sep 17 00:00:00 2001 From: Hiddify Date: Tue, 20 Feb 2024 09:30:34 +0100 Subject: [PATCH] fix: translation bug, disable signing for pull req --- .github/workflows/build.yml | 4 ++-- assets/translations/strings_br.i18n.json | 6 +++--- lib/features/connection/notifier/connection_notifier.dart | 4 ++-- lib/features/intro/widget/intro_page.dart | 2 +- lib/features/profile/data/profile_repository.dart | 2 +- pubspec.lock | 2 +- pubspec.yaml | 1 + 7 files changed, 11 insertions(+), 10 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2034f049..7f9f9e4f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -93,7 +93,7 @@ jobs: tree - name: Setup Android Signing Properties - if: startsWith(matrix.platform,'android') + if: ${{ inputs.upload-artifact && startsWith(matrix.platform,'android') }} run: | echo "${{ secrets.ANDROID_SIGNING_KEY }}" | base64 --decode > android/key.jks echo "storeFile=$(pwd)/android/key.jks" > android/key.properties @@ -102,7 +102,7 @@ jobs: echo "keyAlias=${{ secrets.ANDROID_SIGNING_KEY_ALIAS }}" >> android/key.properties - name: Setup Apple certificate and provisioning profile - if: startsWith(matrix.os,'macos') + if: ${{ inputs.upload-artifact && startsWith(matrix.os,'macos') }} env: BUILD_CERTIFICATE_BASE64: ${{ secrets.APPLE_BUILD_CERTIFICATE_BASE64 }} P12_PASSWORD: ${{ secrets.APPLE_CERTIFICATE_P12_PASSWORD }} diff --git a/assets/translations/strings_br.i18n.json b/assets/translations/strings_br.i18n.json index 5f6c5d24..a23671c4 100644 --- a/assets/translations/strings_br.i18n.json +++ b/assets/translations/strings_br.i18n.json @@ -122,8 +122,9 @@ "lastUpdate": "Última atualização", "updateInterval": "Autilização automática", "updateIntervalDialogTitle": "Intervalo de atualização (em horas)" - }, - "proxies": { + } + }, + "proxies": { "pageTitle": "Proxies", "emptyProxiesMsg": "Nenhum proxy encontrado", "delayTestTooltip": "Testar delay", @@ -149,7 +150,6 @@ "speed": "Velocidade", "totalTransferred": "Total transferido" } - } }, "logs": { "pageTitle": "Logs", diff --git a/lib/features/connection/notifier/connection_notifier.dart b/lib/features/connection/notifier/connection_notifier.dart index 0c44a0e4..9863a6aa 100644 --- a/lib/features/connection/notifier/connection_notifier.dart +++ b/lib/features/connection/notifier/connection_notifier.dart @@ -127,8 +127,8 @@ class ConnectionNotifier extends _$ConnectionNotifier with AppLogger { ) .mapLeft((err) async { loggy.warning("error connecting", err); - loggy.warning( - err); //Go err is not normal object to see the go errors are string and need to be dumped + //Go err is not normal object to see the go errors are string and need to be dumped + loggy.warning(err); if (err.toString().contains("panic")) { await Sentry.captureException(Exception(err.toString())); } diff --git a/lib/features/intro/widget/intro_page.dart b/lib/features/intro/widget/intro_page.dart index 0a8909c5..2cc23879 100644 --- a/lib/features/intro/widget/intro_page.dart +++ b/lib/features/intro/widget/intro_page.dart @@ -125,7 +125,7 @@ class IntroPage extends HookConsumerWidget with PresLogger { _getRegionLocale(jsonData['country']?.toString() ?? ""); loggy.debug( - 'Region: ${regionLocale.region} Locale: ${regionLocale.locale}'); + 'Region: ${regionLocale.region} Locale: ${regionLocale.locale}',); await ref .read(regionNotifierProvider.notifier) .update(regionLocale.region); diff --git a/lib/features/profile/data/profile_repository.dart b/lib/features/profile/data/profile_repository.dart index 64591e1d..9343a651 100644 --- a/lib/features/profile/data/profile_repository.dart +++ b/lib/features/profile/data/profile_repository.dart @@ -423,7 +423,7 @@ class ProfileRepositoryImpl loggy.debug( "only [$headersFound] headers found, checking file content for possible information", ); - var content = await File(path).readAsString(); + final content = await File(path).readAsString(); final contentHeaders = parseHeadersFromContent(content); for (final entry in contentHeaders.entries) { if (!headers.keys.contains(entry.key) && entry.value.isNotEmpty) { diff --git a/pubspec.lock b/pubspec.lock index 0b5b4908..47175569 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -726,7 +726,7 @@ packages: source: hosted version: "0.15.4" http: - dependency: transitive + dependency: "direct main" description: name: http sha256: a2bbf9d017fcced29139daa8ed2bba4ece450ab222871df93ca9eec6f80c34ba diff --git a/pubspec.yaml b/pubspec.yaml index 282a863b..d7a7d55d 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -74,6 +74,7 @@ dependencies: dart_mappable: ^4.2.0 fluentui_system_icons: ^1.1.225 circle_flags: ^4.0.2 + http: ^1.2.0 dev_dependencies: flutter_test: