diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index dbc54fd5e..2f33c86bc 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,6 +1,7 @@ name: Publish releases -on: push +on: + workflow_dispatch: permissions: contents: read diff --git a/Makefile b/Makefile index 408018a10..eda5cbea3 100644 --- a/Makefile +++ b/Makefile @@ -244,15 +244,7 @@ require-sentry: @if [[ -z "$(SENTRY)" ]]; then echo 'Missing "sentry-cli" command. See sentry.io for installation instructions.'; exit 1; fi release-autoupdate: require-version - @TAG_COMMIT=$$(git rev-list --abbrev-commit -1 $(TAG)) && \ - if [[ -z "$$TAG_COMMIT" ]]; then \ - echo "Could not find given tag $(TAG)."; \ - fi && \ - for URL in s3://lantern/lantern_update_android_arm-$$VERSION.bz2; do \ - NAME=$$(basename $$URL) && \ - STRIPPED_NAME=$$(echo "$$NAME" | cut -d - -f 1 | sed s/lantern_//).bz2 && \ - s3cmd get --force s3://$(S3_BUCKET)/$$NAME $$STRIPPED_NAME; \ - done && \ + @curl https://s3.amazonaws.com/lantern/lantern-installer.apk | bzip2 > update_android_arm.bz2 && \ $(RUBY) ./create_or_update_release.rb getlantern lantern $$VERSION update_android_arm.bz2 release: require-version require-s3cmd require-wget require-lantern-binaries require-release-track release-prod copy-beta-installers-to-mirrors invalidate-getlantern-dot-org upload-aab-to-play diff --git a/README.md b/README.md index f73c3ea4a..1d18973ff 100644 --- a/README.md +++ b/README.md @@ -173,7 +173,7 @@ To publish a release on Google Play, go to the Lantern App on the [Google Play C ### Enabling Auto-Update for a Sideloaded Release -Just because something's been released to prod doesn't mean clients will auto-update, there's an additional step for that. +Just because something's been released to prod doesn't mean clients will auto-update, there's an additional step for that. The below will release the current production version to autoupdate. Please make sure the VERSION parameter matches the current production version. ``` GH_TOKEN= VERSION=7.2.0 make release-autoupdate diff --git a/android/app/src/main/kotlin/org/getlantern/lantern/MainActivity.kt b/android/app/src/main/kotlin/org/getlantern/lantern/MainActivity.kt index 39bd3401d..def497c1c 100644 --- a/android/app/src/main/kotlin/org/getlantern/lantern/MainActivity.kt +++ b/android/app/src/main/kotlin/org/getlantern/lantern/MainActivity.kt @@ -1,5 +1,7 @@ package org.getlantern.lantern +import android.annotation.SuppressLint +import android.content.Context import android.content.Intent import android.content.IntentFilter import android.content.pm.PackageManager @@ -12,6 +14,7 @@ import android.widget.TextView import androidx.annotation.NonNull import androidx.appcompat.app.AlertDialog import androidx.core.app.ActivityCompat +import androidx.core.content.ContextCompat import io.flutter.embedding.android.FlutterActivity import io.flutter.embedding.engine.FlutterEngine import io.flutter.embedding.engine.FlutterEngineCache @@ -154,11 +157,16 @@ class MainActivity : } } + @SuppressLint("WrongConstant") override fun onStart() { super.onStart() val packageName = activity.packageName IntentFilter("$packageName.intent.VPN_DISCONNECTED").also { - registerReceiver(receiver, it) + ContextCompat.registerReceiver( + this@MainActivity, + receiver, + it, + ContextCompat.RECEIVER_NOT_EXPORTED) } } diff --git a/android/app/src/main/kotlin/org/getlantern/lantern/activity/FreeKassaActivity.kt b/android/app/src/main/kotlin/org/getlantern/lantern/activity/FreeKassaActivity.kt index c94009378..10ebb48e8 100644 --- a/android/app/src/main/kotlin/org/getlantern/lantern/activity/FreeKassaActivity.kt +++ b/android/app/src/main/kotlin/org/getlantern/lantern/activity/FreeKassaActivity.kt @@ -196,17 +196,20 @@ open class FreeKassaActivity : BaseFragmentActivity() { } } } + + val plan = LanternApp.getSession().planByID(planID!!)!! + val currency = plan.currency val u = FreeKassa.getPayURI( merchantId, price!!, - LanternApp.getSession().currency(), + currency, planID!!, secretWordOne, LanternApp.getSession().language, userEmail!!, mapOf( "transactionid" to transactionID, - "paymentcurrency" to LanternApp.getSession().currency() + "paymentcurrency" to currency ) ) Logger.d(TAG, "freeKassa Payment URI: $u") diff --git a/lib/account/privacy_disclosure.dart b/lib/account/privacy_disclosure.dart index c7fac560c..4e15b7598 100644 --- a/lib/account/privacy_disclosure.dart +++ b/lib/account/privacy_disclosure.dart @@ -1,38 +1,44 @@ import 'package:lantern/common/common.dart'; class PrivacyDisclosure extends StatelessWidget { + const PrivacyDisclosure({super.key}); + @override Widget build(BuildContext context) { return FullScreenDialog( widget: Padding( - padding: EdgeInsetsDirectional.only( - start: 33, end: 33), + padding: const EdgeInsetsDirectional.only(start: 33, end: 33), + child: SingleChildScrollView( child: Column( - mainAxisAlignment: MainAxisAlignment.spaceAround, - crossAxisAlignment: CrossAxisAlignment.center, - children: [ - Container( - margin: const EdgeInsetsDirectional.only(top: 38), + mainAxisAlignment: MainAxisAlignment.spaceAround, + crossAxisAlignment: CrossAxisAlignment.center, + children: [ + Container( + margin: const EdgeInsetsDirectional.only(top: 38), child: CText( 'privacy_disclosure_title'.i18n, style: tsSubtitle1.copiedWith(fontSize: 24.0), - )), - Padding( - padding: EdgeInsetsDirectional.only(top: 24, bottom: 24), - child: CText( - 'privacy_disclosure_body'.i18n, - style: tsBody2.copiedWith(fontSize: 14.0, lineHeight: 24.0), - ), ), - const Spacer(), - Container( - margin: const EdgeInsetsDirectional.only(bottom: 38), - child: Button( - width: 200, - text: 'privacy_disclosure_accept'.i18n, - onPressed: () async => await sessionModel.acceptTerms(), - )), - ])), + ), + Padding( + padding: const EdgeInsetsDirectional.only(top: 24, bottom: 24), + child: CText( + 'privacy_disclosure_body'.i18n, + style: tsBody2.copiedWith(fontSize: 14.0, lineHeight: 24.0), + ), + ), + Container( + margin: const EdgeInsetsDirectional.only(bottom: 38), + child: Button( + width: 200, + text: 'privacy_disclosure_accept'.i18n, + onPressed: () async => await sessionModel.acceptTerms(), + ), + ), + ], + ), + ), + ), ); } } diff --git a/lib/account/split_tunneling.dart b/lib/account/split_tunneling.dart index 785cff384..63844c95b 100644 --- a/lib/account/split_tunneling.dart +++ b/lib/account/split_tunneling.dart @@ -25,7 +25,6 @@ class _SplitTunnelingState extends State { void init() async { unawaited(sessionModel.refreshAppsList()); - await sessionModel.trackUserAction('Split tunneling screen shown to user'); var _vpnConnected = await vpnModel.isVpnConnected(); setState(() { vpnConnected = _vpnConnected; diff --git a/lib/common/session_model.dart b/lib/common/session_model.dart index acfe71d05..ae0ca74a1 100644 --- a/lib/common/session_model.dart +++ b/lib/common/session_model.dart @@ -348,14 +348,6 @@ class SessionModel extends Model { ); } - Future trackUserAction( - String message, - ) async { - return methodChannel.invokeMethod('trackUserAction', { - 'message': message, - }); - } - Future redeemResellerCode( String email, String resellerCode,