Skip to content

Commit

Permalink
refactor:clean root project dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
chen56 committed Apr 17, 2024
1 parent 622d43c commit fa80852
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 63 deletions.
8 changes: 5 additions & 3 deletions bin/notecli.dart
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import 'package:path/path.dart' as path;

import 'package:analyzer/dart/analysis/utilities.dart' as analyzer_util;
import 'package:watcher/watcher.dart';
import 'package:yaml_edit/yaml_edit.dart';
import 'package:yaml_edit/yaml_edit.dart' show YamlEditor;

import 'package:note_dart/src/utils_core.dart';

Expand Down Expand Up @@ -175,7 +175,9 @@ $fields
// ignore: non_constant_identifier_names
Future<List<NoteParseResult>> _genAll_note_g_dart() async {
var result = await _noteLibs.map((e) => e.gen()).asyncExpand((e) => e.asStream()).toList();
result.forEach((e)=>_log("gen note: $e"));
for (var e in result) {
_log("gen note: $e");
}
var pubspec = await _pubspec();
var toUpdate = result.map((e) => e.noteLib.asset).sorted((a, b) => a.compareTo(b));
pubspec.noteAssetsUpdate(toUpdate);
Expand Down Expand Up @@ -531,7 +533,7 @@ class NoteParseResult {

@override
String toString() {
return "${file}";
return "$file";
}
}

Expand Down
60 changes: 2 additions & 58 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,76 +8,20 @@ environment:
sdk: '>=3.3.0 <4.0.0'

dependencies:
# flutter:
# sdk: flutter

meta: ^1.11.0
collection: ^1.18.0
path: ^1.8.3
file: ^7.0.0

markdown: ^7.0.0
highlight: ^0.7.0
code_builder: ^4.4.0
dart_style: ^2.0.0



# plugin
shared_preferences: ^2.2.2
flutter_markdown: ^0.6.14
flutter_highlight: ^0.7.0
args: ^2.4.2
analyzer: ^6.4.1
glob: ^2.1.1
watcher: ^1.1.0

yaml_edit: ^2.2.0
note_dart:
path: packages/note_dart

# async: ^2.11.0
dev_dependencies:
flutter_test:
sdk: flutter
flutter_lints:
yaml_edit: ^2.2.0

# for NoteDevTool
stack_trace: ^1.11.0

# For information on the generic Dart part of this file, see the
# following page: https://dart.dev/tools/pub/pubspec

# The following section is specific to Flutter packages.
flutter:

# To add assets to your package, add an assets section, like this:
# assets:
# - images/a_dot_burr.jpeg
# - images/a_dot_ham.jpeg
#
# For details regarding assets in packages, see
# https://flutter.dev/assets-and-images/#from-packages
#
# An image asset can refer to one or more resolution-specific "variants", see
# https://flutter.dev/assets-and-images/#resolution-aware

# To add custom fonts to your package, add a fonts section here,
# in this "flutter" section. Each entry in this list should have a
# "family" key with the font family name, and a "fonts" key with a
# list giving the asset and other descriptors for the font. For
# example:
# fonts:
# - family: Schyler
# fonts:
# - asset: fonts/Schyler-Regular.ttf
# - asset: fonts/Schyler-Italic.ttf
# style: italic
# - family: Trajan Pro
# fonts:
# - asset: fonts/TrajanPro.ttf
# - asset: fonts/TrajanPro_Bold.ttf
# weight: 700
#
# For details regarding fonts in packages, see
# https://flutter.dev/custom-fonts/#from-packages
test:
2 changes: 1 addition & 1 deletion test/tools/gen_assets_test.dart
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import 'package:file/file.dart';
import 'package:file/memory.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:path/path.dart' as path;
import 'package:test/test.dart';

import '../../tools/note_dev_gen.dart';

Expand Down
2 changes: 1 addition & 1 deletion test/tools/note_dev_gen_test.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import 'package:file/memory.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:test/test.dart';

import '../../tools/note_dev_gen.dart';

Expand Down

0 comments on commit fa80852

Please sign in to comment.