Skip to content
This repository has been archived by the owner on Feb 22, 2023. It is now read-only.

Commit

Permalink
Add pubspec convention checks (#3984)
Browse files Browse the repository at this point in the history
  • Loading branch information
stuartmorgan authored May 28, 2021
1 parent 0fff514 commit 2b1cc57
Show file tree
Hide file tree
Showing 55 changed files with 747 additions and 234 deletions.
1 change: 1 addition & 0 deletions .cirrus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ task:
- ./script/tool_runner.sh publish-check
- name: format
format_script: ./script/tool_runner.sh format --fail-on-change
pubspec_script: ./script/tool_runner.sh pubspec-check
license_script:
- dart script/tool/lib/src/main.dart license-check
- name: test
Expand Down
8 changes: 4 additions & 4 deletions packages/android_alarm_manager/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ name: android_alarm_manager_example
description: Demonstrates how to use the android_alarm_manager plugin.
publish_to: none

environment:
sdk: '>=2.12.0 <3.0.0'
flutter: ">=1.20.0"

dependencies:
flutter:
sdk: flutter
Expand All @@ -27,7 +31,3 @@ dev_dependencies:

flutter:
uses-material-design: true

environment:
sdk: '>=2.12.0 <3.0.0'
flutter: ">=1.20.0"
25 changes: 13 additions & 12 deletions packages/android_alarm_manager/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,17 +1,13 @@
name: android_alarm_manager
description: Flutter plugin for accessing the Android AlarmManager service, and
running Dart code in the background when alarms fire.
repository: https://github.com/flutter/plugins/tree/master/packages/android_alarm_manager
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+android_alarm_manager%22
version: 2.0.2
homepage: https://github.com/flutter/plugins/tree/master/packages/android_alarm_manager

dependencies:
flutter:
sdk: flutter

dev_dependencies:
flutter_test:
sdk: flutter
pedantic: ^1.10.0
environment:
sdk: '>=2.12.0 <3.0.0'
flutter: ">=1.20.0"

flutter:
plugin:
Expand All @@ -20,6 +16,11 @@ flutter:
package: io.flutter.plugins.androidalarmmanager
pluginClass: AndroidAlarmManagerPlugin

environment:
sdk: '>=2.12.0 <3.0.0'
flutter: ">=1.20.0"
dependencies:
flutter:
sdk: flutter

dev_dependencies:
flutter_test:
sdk: flutter
pedantic: ^1.10.0
8 changes: 4 additions & 4 deletions packages/android_intent/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ name: android_intent_example
description: Demonstrates how to use the android_intent plugin.
publish_to: none

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.20.0"

dependencies:
flutter:
sdk: flutter
Expand All @@ -23,7 +27,3 @@ dev_dependencies:
# The following section is specific to Flutter.
flutter:
uses-material-design: true

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.20.0"
11 changes: 6 additions & 5 deletions packages/android_intent/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
name: android_intent
description: Flutter plugin for launching Android Intents. Not supported on iOS.
homepage: https://github.com/flutter/plugins/tree/master/packages/android_intent
repository: https://github.com/flutter/plugins/tree/master/packages/android_intent
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+android_intent%22
version: 2.0.2

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.20.0"

flutter:
plugin:
platforms:
Expand All @@ -22,7 +27,3 @@ dev_dependencies:
sdk: flutter
pedantic: ^1.10.0
build_runner: ^1.11.1

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.20.0"
8 changes: 4 additions & 4 deletions packages/battery/battery/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ name: battery_example
description: Demonstrates how to use the battery plugin.
publish_to: none

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"

dependencies:
flutter:
sdk: flutter
Expand All @@ -22,7 +26,3 @@ dev_dependencies:

flutter:
uses-material-design: true

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"
11 changes: 6 additions & 5 deletions packages/battery/battery/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
name: battery
description: Flutter plugin for accessing information about the battery state
(full, charging, discharging) on Android and iOS.
homepage: https://github.com/flutter/plugins/tree/master/packages/battery/battery
repository: https://github.com/flutter/plugins/tree/master/packages/battery/battery
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+battery%22
version: 2.0.3

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"

flutter:
plugin:
platforms:
Expand All @@ -27,7 +32,3 @@ dev_dependencies:
sdk: flutter
pedantic: ^1.10.0
test: ^1.16.3

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"
11 changes: 6 additions & 5 deletions packages/battery/battery_platform_interface/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
name: battery_platform_interface
description: A common platform interface for the battery plugin.
homepage: https://github.com/flutter/plugins/tree/master/packages/battery
repository: https://github.com/flutter/plugins/tree/master/packages/battery/battery_platform_interface
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+battery%22
# NOTE: We strongly prefer non-breaking changes, even at the expense of a
# less-clean API. See https://flutter.dev/go/platform-interface-breaking-changes
version: 2.0.1

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.20.0"

dependencies:
flutter:
sdk: flutter
Expand All @@ -16,7 +21,3 @@ dev_dependencies:
sdk: flutter
mockito: ^5.0.0
pedantic: ^1.10.0

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.20.0"
8 changes: 4 additions & 4 deletions packages/camera/camera/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ name: camera_example
description: Demonstrates how to use the camera plugin.
publish_to: none

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.22.0"

dependencies:
camera:
# When depending on this package from a real application you should use:
Expand All @@ -26,7 +30,3 @@ dev_dependencies:

flutter:
uses-material-design: true

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.22.0"
8 changes: 4 additions & 4 deletions packages/connectivity/connectivity/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ name: connectivity_example
description: Demonstrates how to use the connectivity plugin.
publish_to: none

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"

dependencies:
flutter:
sdk: flutter
Expand All @@ -23,7 +27,3 @@ dev_dependencies:

flutter:
uses-material-design: true

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"
11 changes: 6 additions & 5 deletions packages/connectivity/connectivity/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
name: connectivity
description: Flutter plugin for discovering the state of the network (WiFi &
mobile/cellular) connectivity on Android and iOS.
homepage: https://github.com/flutter/plugins/tree/master/packages/connectivity/connectivity
repository: https://github.com/flutter/plugins/tree/master/packages/connectivity/connectivity
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+connectivity%22
version: 3.0.6

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"

flutter:
plugin:
platforms:
Expand Down Expand Up @@ -33,7 +38,3 @@ dev_dependencies:
plugin_platform_interface: ^2.0.0
pedantic: ^1.10.0
test: ^1.16.3

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"
9 changes: 5 additions & 4 deletions packages/connectivity/connectivity_for_web/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
name: connectivity_for_web
description: An implementation for the web platform of the Flutter `connectivity` plugin. This uses the NetworkInformation Web API, with a fallback to Navigator.onLine.
repository: https://github.com/flutter/plugins/tree/master/packages/connectivity/connectivity_for_web
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+connectivity%22
version: 0.4.0

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.20.0"

flutter:
plugin:
platforms:
Expand All @@ -20,7 +25,3 @@ dependencies:
dev_dependencies:
flutter_test:
sdk: flutter

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.20.0"
8 changes: 4 additions & 4 deletions packages/connectivity/connectivity_macos/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ name: connectivity_example
description: Demonstrates how to use the connectivity plugin.
publish_to: none

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.10.0"

dependencies:
flutter:
sdk: flutter
Expand All @@ -23,7 +27,3 @@ dev_dependencies:

flutter:
uses-material-design: true

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.10.0"
11 changes: 6 additions & 5 deletions packages/connectivity/connectivity_macos/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
name: connectivity_macos
description: macOS implementation of the connectivity plugin.
repository: https://github.com/flutter/plugins/tree/master/packages/connectivity/connectivity_macos
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+connectivity%22
version: 0.2.1+1
homepage: https://github.com/flutter/plugins/tree/master/packages/connectivity/connectivity_macos

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.20.0"

flutter:
plugin:
Expand All @@ -10,10 +15,6 @@ flutter:
macos:
pluginClass: ConnectivityPlugin

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.20.0"

dependencies:
flutter:
sdk: flutter
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
name: connectivity_platform_interface
description: A common platform interface for the connectivity plugin.
homepage: https://github.com/flutter/plugins/tree/master/packages/connectivity/connectivity_platform_interface
repository: https://github.com/flutter/plugins/tree/master/packages/connectivity/connectivity_platform_interface
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+connectivity%22
# NOTE: We strongly prefer non-breaking changes, even at the expense of a
# less-clean API. See https://flutter.dev/go/platform-interface-breaking-changes
version: 2.0.1

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"

dependencies:
flutter:
sdk: flutter
Expand All @@ -15,7 +20,3 @@ dev_dependencies:
flutter_test:
sdk: flutter
pedantic: ^1.10.0

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"
8 changes: 4 additions & 4 deletions packages/device_info/device_info/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ name: device_info_example
description: Demonstrates how to use the device_info plugin.
publish_to: none

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"

dependencies:
flutter:
sdk: flutter
Expand All @@ -22,7 +26,3 @@ dev_dependencies:

flutter:
uses-material-design: true

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"
11 changes: 6 additions & 5 deletions packages/device_info/device_info/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
name: device_info
description: Flutter plugin providing detailed information about the device
(make, model, etc.), and Android or iOS version the app is running on.
homepage: https://github.com/flutter/plugins/tree/master/packages/device_info
repository: https://github.com/flutter/plugins/tree/master/packages/device_info/device_info
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+device_info%22
version: 2.0.2

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"

flutter:
plugin:
platforms:
Expand All @@ -22,7 +27,3 @@ dev_dependencies:
flutter_test:
sdk: flutter
pedantic: ^1.10.0

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"
11 changes: 6 additions & 5 deletions packages/device_info/device_info_platform_interface/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
name: device_info_platform_interface
description: A common platform interface for the device_info plugin.
homepage: https://github.com/flutter/plugins/tree/master/packages/device_info
repository: https://github.com/flutter/plugins/tree/master/packages/device_info/device_info_platform_interface
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+device_info%22
# NOTE: We strongly prefer non-breaking changes, even at the expense of a
# less-clean API. See https://flutter.dev/go/platform-interface-breaking-changes
version: 2.0.1

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.9.1+hotfix.4"

dependencies:
flutter:
sdk: flutter
Expand All @@ -16,7 +21,3 @@ dev_dependencies:
sdk: flutter
test: ^1.16.3
pedantic: ^1.10.0

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.9.1+hotfix.4"
Loading

0 comments on commit 2b1cc57

Please sign in to comment.