Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove platform dependent preprocess script #601

Merged
merged 1 commit into from
Dec 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions .github/workflows/violet-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,6 @@ jobs:
cd lib/server
wget -q ${{ secrets.SECRET_SALT }} || echo 'String getValid(String vToken) { return vToken; }' > salt.dart
wget -q ${{ secrets.SECRET_WSALT }} || echo 'String getValid(String vToken) { return vToken; }' > wsalt.dart
cd ../..
python3 preprocess-ios.py

- name: Podfile
run: |
Expand Down Expand Up @@ -151,8 +149,6 @@ jobs:
cd lib/server
wget -q ${{ secrets.SECRET_SALT }} || echo 'String getValid(String vToken) { return vToken; }' > salt.dart
wget -q ${{ secrets.SECRET_WSALT }} || echo 'String getValid(String vToken) { return vToken; }' > wsalt.dart
cd ../..
python3 preprocess-android.py

- name: Build
run: |
Expand Down
4 changes: 2 additions & 2 deletions violet/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import 'package:flutter/cupertino.dart';
import 'package:flutter/gestures.dart';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:flutter_downloader/flutter_downloader.dart'; // @dependent: android
import 'package:flutter_downloader/flutter_downloader.dart';
import 'package:flutter_localizations/flutter_localizations.dart';
import 'package:fullscreen_window/fullscreen_window.dart';
import 'package:get/get.dart';
Expand All @@ -41,7 +41,7 @@ Future<void> main() async {
await Logger.init();

if (Platform.isAndroid || Platform.isIOS) {
await FlutterDownloader.initialize(); // @dependent: android
await FlutterDownloader.initialize();
}
FlareCache.doesPrune = false;
FlutterError.onError = recordFlutterError;
Expand Down
7 changes: 2 additions & 5 deletions violet/lib/update/update_manager.dart
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import 'dart:ui';

import 'package:connectivity_plus/connectivity_plus.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter_downloader/flutter_downloader.dart'; // @dependent: android
import 'package:flutter_downloader/flutter_downloader.dart';
import 'package:open_file/open_file.dart';
import 'package:permission_handler/permission_handler.dart';
import 'package:shared_preferences/shared_preferences.dart';
Expand All @@ -27,11 +27,10 @@ class UpdateManager {
// Update is only available for Android.
if (Platform.isAndroid) {
if (!context.mounted) return;
updateCheckAndDownload(context); // @dependent: android
updateCheckAndDownload(context);
}
}

// @dependent: android [
static final ReceivePort _port = ReceivePort();

@pragma('vm:entry-point')
Expand Down Expand Up @@ -109,6 +108,4 @@ class UpdateManager {
await prefs.setBool('usevioletserver_check', false);
});
}

// @dependent: android ]
}
112 changes: 0 additions & 112 deletions violet/preprocess-android.py

This file was deleted.

112 changes: 0 additions & 112 deletions violet/preprocess-ios.py

This file was deleted.

Loading