Skip to content

Commit

Permalink
Version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
leoafarias committed Mar 25, 2021
1 parent 911c67a commit 27ba8f0
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 30 deletions.
4 changes: 2 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
## 1.1.0
## 2.0.0-beta.1

- Deprecated checkUpdatePrinter
- Changed latest version to display stable version only
- Null safety

## 1.0.9

Expand Down
2 changes: 2 additions & 0 deletions lib/src/helpers/console_helper.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import '../../pub_api_client.dart';

/// Checks and prints if [currentVersion] of a [package]
/// is not the latest version.
@Deprecated(
'''Implement this function within your app/package. It will be removed from the package''')
Future<bool> checkUpdatePrinter(
String package, {
required String currentVersion,
Expand Down
46 changes: 23 additions & 23 deletions lib/src/helpers/deps_builder.dart
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
import 'dart:async';
import 'dart:convert';
// import 'dart:async';
// import 'dart:convert';

import 'package:build/build.dart';
import 'package:pub_api_client/src/helpers/google_packages.dart';
// import 'package:build/build.dart';
// import 'package:pub_api_client/src/helpers/google_packages.dart';

Builder googleDepsBuilder([BuilderOptions? options]) => _DepsBuilder();
// Builder googleDepsBuilder([BuilderOptions? options]) => _DepsBuilder();

class _DepsBuilder implements Builder {
@override
Future build(BuildStep buildStep) async {
final googleDeps = await getGooglePackages();
final deps = jsonEncode(googleDeps);
await buildStep.writeAsString(
AssetId(buildStep.inputId.package,
'lib/src/helpers/google_packages_list.dart'),
'''
// Generated code. Do not modify.
const googlePackagesList = $googleDeps ;
''');
}
// class _DepsBuilder implements Builder {
// @override
// Future build(BuildStep buildStep) async {
// final googleDeps = await getGooglePackages();
// final deps = jsonEncode(googleDeps);
// await buildStep.writeAsString(
// AssetId(buildStep.inputId.package,
// 'lib/src/helpers/google_packages_list.dart'),
// '''
// // Generated code. Do not modify.
// const googlePackagesList = $googleDeps ;
// ''');
// }

@override
final buildExtensions = const {
r'$lib$': ['src/helpers/google_packages_list.dart']
};
}
// @override
// final buildExtensions = const {
// r'$lib$': ['src/helpers/google_packages_list.dart']
// };
// }
2 changes: 1 addition & 1 deletion lib/src/version.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 3 additions & 4 deletions pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,26 +1,25 @@
name: pub_api_client
description: An API Client for Pub to interact with public package information.
version: 1.0.9
version: 2.0.0-beta.1
homepage: https://github.com/leoafarias/pub_api_client

environment:
sdk: '>=2.12.0 <3.0.0'

dependencies:
pub_semver: ^2.0.0
freezed_annotation: ^0.14.1
http: ^0.13.1
json_annotation: ^4.0.1
pub_semver: ^2.0.0
pubspec: ^2.0.1
pubspec_parse: ^1.0.0



dev_dependencies:
build_runner: ^1.12.2
build_version: ^2.0.2
freezed: ^0.14.1+1
json_serializable: ^4.1.0
pedantic: ^1.11.0

test: ^1.16.8
test_cov: ^1.0.1

0 comments on commit 27ba8f0

Please sign in to comment.