From a5617d8dcd5f29689e2b4f40d378ed4e9db0374a Mon Sep 17 00:00:00 2001 From: debuggerx Date: Mon, 17 Apr 2023 17:18:19 +0800 Subject: [PATCH] remove unused packages. --- lib/main.dart | 8 ++++---- pubspec.yaml | 6 ++---- version.dart | 2 ++ 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/main.dart b/lib/main.dart index ce0cff9..ba1dae9 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -9,7 +9,7 @@ import 'package:flutter/services.dart'; import 'package:flutter_acrylic/flutter_acrylic.dart'; import 'package:url_launcher/url_launcher_string.dart'; import 'package:window_manager/window_manager.dart'; -import 'package:zbar_scan_plugin/zbar_scan_plugin.dart' as ZBar; +import 'package:zbar_scan_plugin/zbar_scan_plugin.dart' as zbar; Future main() async { WidgetsFlutterBinding.ensureInitialized(); @@ -72,7 +72,7 @@ enum Status { class _MyHomePageState extends State { Offset currentWindowPos = Offset.zero; Status status = Status.standBy; - List codes = []; + List codes = []; @override void initState() { @@ -115,10 +115,10 @@ class _MyHomePageState extends State { super.initState(); } - static Future> scan(dynamic _) async { + static Future> scan(dynamic _) async { var imagePath = '/tmp/${DateTime.now().toIso8601String()}.png'; Process.runSync('scrot', [imagePath]); - var result = ZBar.scan(imagePath); + var result = zbar.scan(imagePath); File(imagePath).delete(); return result; } diff --git a/pubspec.yaml b/pubspec.yaml index a0295d4..a3d0dc6 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -34,16 +34,14 @@ dependencies: # The following adds the Cupertino Icons font to your application. # Use with the CupertinoIcons class for iOS style icons. - cupertino_icons: ^1.0.2 window_manager: ^0.3.2 flutter_acrylic: ^1.1.2 - image: ^3.3.0 auto_size_text: ^3.0.0 url_launcher: ^6.1.10 + collection: ^1.17.0 zbar_scan_plugin: git: url: https://github.com/debuggerx01/zbar_scan_plugin.git - collection: ^1.17.0 dev_dependencies: flutter_test: @@ -54,7 +52,7 @@ dev_dependencies: # activated in the `analysis_options.yaml` file located at the root of your # package. See that file for information about deactivating specific lint # rules and activating additional ones. - flutter_lints: ^2.0.0 + flutter_lints: ^2.0.1 yaml: any # For information on the generic Dart part of this file, see the diff --git a/version.dart b/version.dart index 1ddf4e9..3048225 100644 --- a/version.dart +++ b/version.dart @@ -1,3 +1,5 @@ +// ignore_for_file: avoid_print + import 'dart:io'; import 'package:yaml/yaml.dart';