Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from 3 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
1 change: 1 addition & 0 deletions packages/android_alarm_manager/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: android_alarm_manager_example
description: Demonstrates how to use the android_alarm_manager plugin.
publish_to: none

dependencies:
flutter:
Expand Down
1 change: 1 addition & 0 deletions packages/android_intent/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: android_intent_example
description: Demonstrates how to use the android_intent plugin.
publish_to: none

dependencies:
flutter:
Expand Down
1 change: 1 addition & 0 deletions packages/battery/battery/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: battery_example
description: Demonstrates how to use the battery plugin.
publish_to: none

dependencies:
flutter:
Expand Down
1 change: 1 addition & 0 deletions packages/camera/camera/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: camera_example
description: Demonstrates how to use the camera plugin.
publish_to: none

dependencies:
camera:
Expand Down
1 change: 1 addition & 0 deletions packages/connectivity/connectivity/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: connectivity_example
description: Demonstrates how to use the connectivity plugin.
publish_to: none

dependencies:
flutter:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: connectivity_example
description: Demonstrates how to use the connectivity plugin.
publish_to: none

dependencies:
flutter:
Expand Down
1 change: 1 addition & 0 deletions packages/device_info/device_info/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: device_info_example
description: Demonstrates how to use the device_info plugin.
publish_to: none

dependencies:
flutter:
Expand Down
2 changes: 1 addition & 1 deletion packages/espresso/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: espresso_example
description: Demonstrates how to use the espresso plugin.
publish_to: 'none'
publish_to: none

environment:
sdk: ">=2.12.0-259.9.beta <3.0.0"
Expand Down
3 changes: 1 addition & 2 deletions packages/file_selector/file_selector/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
name: example
description: A new Flutter project.

publish_to: 'none' # Remove this line if you wish to publish to pub.dev
publish_to: none

version: 1.0.0+1

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: flutter_plugin_android_lifecycle_example
description: Demonstrates how to use the flutter_plugin_android_lifecycle plugin.
publish_to: none

dependencies:
flutter:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: google_maps_flutter_example
description: Demonstrates how to use the google_maps_flutter plugin.
publish_to: none

environment:
sdk: '>=2.12.0-259.9.beta <3.0.0'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: google_sign_in_example
description: Example of Google Sign-In plugin.
publish_to: none

dependencies:
flutter:
Expand Down
2 changes: 1 addition & 1 deletion packages/image_picker/image_picker/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: image_picker_example
description: Demonstrates how to use the image_picker plugin.
author: Flutter Team <[email protected]>
publish_to: none

dependencies:
video_player: ^2.0.0-nullsafety.7
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: in_app_purchase_example
description: Demonstrates how to use the in_app_purchase plugin.
author: Flutter Team <[email protected]>
publish_to: none

dependencies:
flutter:
Expand Down
2 changes: 1 addition & 1 deletion packages/integration_test/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: integration_test_example
description: Demonstrates how to use the integration_test plugin.
publish_to: 'none'
publish_to: none

environment:
sdk: ">=2.1.0 <3.0.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/ios_platform_images/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: ios_platform_images_example
description: Demonstrates how to use the ios_platform_images plugin.
publish_to: 'none'
publish_to: none
homepage: https://github.com/flutter/plugins/tree/master/packages/ios_platform_images/ios_platform_images

environment:
Expand Down
1 change: 1 addition & 0 deletions packages/local_auth/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: local_auth_example
description: Demonstrates how to use the local_auth plugin.
publish_to: none

dependencies:
flutter:
Expand Down
1 change: 1 addition & 0 deletions packages/package_info/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: package_info_example
description: Demonstrates how to use the package_info plugin.
publish_to: none

dependencies:
flutter:
Expand Down
1 change: 1 addition & 0 deletions packages/path_provider/path_provider/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: path_provider_example
description: Demonstrates how to use the path_provider plugin.
publish_to: none

dependencies:
flutter:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
name: path_provider_example
description: Demonstrates how to use the path_provider plugin.
publish_to: none

dependencies:
dependencie:
flutter:
sdk: flutter
path_provider_macos:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: path_provider_example
description: Demonstrates how to use the path_provider plugin.
publish_to: none

dependencies:
flutter:
Expand Down
1 change: 1 addition & 0 deletions packages/quick_actions/quick_actions/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: quick_actions_example
description: Demonstrates how to use the quick_actions plugin.
publish_to: none

dependencies:
flutter:
Expand Down
1 change: 1 addition & 0 deletions packages/sensors/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: sensors_example
description: Demonstrates how to use the sensors plugin.
publish_to: none

dependencies:
flutter:
Expand Down
1 change: 1 addition & 0 deletions packages/share/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: share_example
description: Demonstrates how to use the share plugin.
publish_to: none

dependencies:
flutter:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: shared_preferences_example
description: Demonstrates how to use the shared_preferences plugin.
publish_to: none

dependencies:
flutter:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: shared_preferences_linux_example
description: Demonstrates how to use the shared_preferences_linux plugin.
publish_to: none

dependencies:
flutter:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: shared_preferences_example
description: Demonstrates how to use the shared_preferences plugin.
publish_to: none

dependencies:
flutter:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: shared_preferences_windows_example
description: Demonstrates how to use the shared_preferences_windows plugin.
publish_to: none

environment:
sdk: ">=2.12.0-259.9.beta <3.0.0"
Expand Down
1 change: 1 addition & 0 deletions packages/url_launcher/url_launcher/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: url_launcher_example
description: Demonstrates how to use the url_launcher plugin.
publish_to: none

dependencies:
flutter:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: url_launcher_example
description: Demonstrates how to use the url_launcher plugin.
publish_to: none

dependencies:
flutter:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: url_launcher_example
description: Demonstrates how to use the url_launcher plugin.
publish_to: none

dependencies:
flutter:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: url_launcher_example
description: Demonstrates the Windows implementation of the url_launcher plugin.
publish_to: none

dependencies:
flutter:
Expand Down
1 change: 0 additions & 1 deletion packages/video_player/video_player/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
name: video_player_example
description: Demonstrates how to use the video_player plugin.
version: 0.0.1
publish_to: none

dependencies:
Expand Down
1 change: 1 addition & 0 deletions packages/webview_flutter/example/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: webview_flutter_example
description: Demonstrates how to use the webview_flutter plugin.
publish_to: none

environment:
sdk: ">=2.12.0-259.9.beta <3.0.0"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: wifi_info_flutter_example
description: Demonstrates how to use the wifi_info_flutter plugin.
publish_to: 'none'
publish_to: none

environment:
sdk: ">=2.12.0-259.9.beta <3.0.0"
Expand Down
8 changes: 5 additions & 3 deletions script/tool/lib/src/common.dart
Original file line number Diff line number Diff line change
Expand Up @@ -596,10 +596,12 @@ class GitVersionFinder {
return changedFiles.toList();
}

/// Get the package version specified in the pubspec file in `pubspecPath` and at the revision of `gitRef`.
Future<Version> getPackageVersion(String pubspecPath, String gitRef) async {
/// Get the package version specified in the pubspec file in `pubspecPath` and
/// at the revision of `gitRef` (defaulting to the base if not provided).
Future<Version> getPackageVersion(String pubspecPath, {String gitRef}) async {
final String ref = gitRef ?? (await _getBaseSha());
final io.ProcessResult gitShow =
await baseGitDir.runCommand(<String>['show', '$gitRef:$pubspecPath']);
await baseGitDir.runCommand(<String>['show', '$ref:$pubspecPath']);
final String fileContent = gitShow.stdout as String;
final String versionString = loadYaml(fileContent)['version'] as String;
return versionString == null ? null : Version.parse(versionString);
Expand Down
Loading