Commit Graph

30 Commits

Author SHA1 Message Date
stuartmorgan-g
b280843740 Instruct agents to create a repo root alias (#10165)
In my trials so far, Jules struggles to run the repo tooling commands once it has moved into a target directory, because it frequently tries to use a root-relative path instead of an absolute path. To try to reduce that problem, this instructs the agent to explicitly create an alias so that the later commands that reference REPO_ROOT as a placeholder will, hopefully, be run exactly as written in the examples instead.

Also, to reduce unnecessary working directory confusion, switch to `dart pub get -C` instead of `cd` followed by `dart pub get` for initializing the tooling. (Also makes the same change to the tool README, because why not have humans run one command instead of three.)
2025-10-03 23:15:06 +00:00
stuartmorgan-g
5d785a06c0 [tool] Combine code analysis commands into analyze (#9860)
Folds native code analysis commands into `analyze` to simplify the set of commands:
- `lint-android` is now `analyze --no-dart --android`
- `xcode-analyze --ios` is now `analyze --no-dart --ios`
- `xcode-analyze --macos` is now `analyze --no-dart --macos`

In practice `--no-dart` is mostly there for CI; Dart analysis is fast enough that for local plugin development the new expected use case would likely be `analyze --whateverplatorm`, and it will run analysis on all relevant code in the package.

Part of https://github.com/flutter/flutter/issues/173413

## Pre-Review Checklist

**Note**: The Flutter team is currently trialing the use of [Gemini Code Assist for GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code). Comments from the `gemini-code-assist` bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

[^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
2025-09-02 17:11:20 +00:00
Rexios
cc9ff47058 [tool] Add note about clang version used in CI to tool readme (#7273)
This repo uses clang 15 to format files. Newer versions of clang format code differently. This PR adds a note to the tool README about this and adds sample instructions for how to install clang 15 on macOS. We might want to add instructions for other platforms.

Fixes https://github.com/flutter/flutter/issues/152651

Additional context
- https://github.com/flutter/packages/pull/7267
- https://github.com/flutter/packages/pull/7271
2024-08-02 13:05:24 +00:00
stuartmorgan
5cc71d00ac Update Flutter wiki links (#6789)
Updates all links to the Flutter wiki to point to their new location in the flutter/flutter repository. (The sole exception is a link to a doc that doesn't have a final home yet, and is linked from legacy code anyway so doesn't really need to be updated.)

While touching the PR template, makes a few minor improvements:
- Removes the breaking change discussion that doesn't apply to this repository, as breaking changes are handled totally differently for packages (and is covered by the link to docs about Dart versioning).
- Adds text and a link to reflect the fact that some PRs can be changelog-exempt.
2024-05-26 12:47:23 +00:00
Ian Hickson
bd5d19113e [flutter_plugin_tools] Reimplements the excerpt system inline in the tool, rather than relying on a separate package. (#4417)
* Allows excerpts to come from any package, not just examples.
* Fixes a bug in the excerpting logic that was causing a stray `}` to appear in one example.
* Removes the need for `build.excerpt.yaml` files.
* Remove the dependency on build_runner for excerpts.
* Reduces the time to generate the excerpts from about 10 minutes to about 5 seconds.
* Almost certainly fixes https://github.com/flutter/flutter/issues/107180 (untested).

The new logic is not quite backwards compatible; the `path-base` feature now specifies a real path to the actual source directories, rather than a path into the invisible generated `excerpts/` directory with its special structure. Also, a number of features from the previous package that were not actually used in this repository are no longer supported (such as having multiple section names per `#docregion` pragma).
2023-07-11 21:49:24 +00:00
stuartmorgan
eed9b68284 [tool] Allow running from anywhere (#4199)
Now that the repo tooling is always run from source, not via `pub global`, we no longer need to infer the repo location from the current directory. Instead, hard-code knowledge of where the repository root is. This makes it much easier to run the tooling, since it's common to be in a package directory rather than the repo root.

To make it even easier to run from within a package, this also adds a `--current-package` as an alternative to `--packages`. This makes it possible to, e.g., write local wrapper scripts that run a specific set of commands on whatever the current package happens to be (such as a generic version of the script discussed in https://github.com/flutter/packages/pull/4129).

As related cleanup, makes the tool non-publishable (we haven't been publishing it since the repo merge, but I never made it unpublishable; this is important now that it would not work if published) and remove the LICENSE and CHANGELOG since it's no longer a stand-alone package.

Fixes https://github.com/flutter/flutter/issues/128231
Fixes https://github.com/flutter/flutter/issues/128232
2023-06-13 17:24:56 +00:00
stuartmorgan
3df3ba528e [tool] Add initial update-dependency command (#3632)
[tool] Add initial `update-dependency` command
2023-04-03 21:23:11 +00:00
stuartmorgan
09544999b2 [tool] Provide a --base-branch flag (#3322)
[tool] Provide a --base-branch flag
2023-03-01 11:55:21 +00:00
stuartmorgan
25f0f702e5 [various] Update flutter/plugins links (#3256)
Updates links and references to `flutter/plugins` to use `flutter/packages` instead, including making the `repository` pubspec.yaml check stricter in the repo tooling to ensure all packages are pointing to the right place.

Exceptions to the updates are:
- Changelog entries.
- Links to pull requests.

This will re-publish all the moved plugins, thus fixing the current redness of `release` (due to the current versions not being tagged in this repository).
2023-02-22 13:45:11 -05:00
Stuart Morgan
91d967c60d Update docs 2023-02-13 11:54:41 -05:00
stuartmorgan
9974a8ef44 [tool] Clean up "plugin" references (#6503) 2022-09-27 19:43:04 +00:00
Greg Spencer
edcd2662e6 Add missing submodule command to setup for packages repo. (#6276) 2022-09-02 13:22:13 +00:00
Tarrin Neal
2e2d4d265d Adds info about commands requiring Flutter-bundled dart (#6312) 2022-08-26 18:40:55 +00:00
Loïc Sharma
1fbf2f6219 [camera_windows] Improve several error handling scenarios (#6149) 2022-07-28 23:16:05 +00:00
stuartmorgan
66824fd7e6 [various] Clean up obsolete references to "master" (#5912) 2022-06-06 12:23:10 -07:00
stuartmorgan
dd2fc61b1c [tools] Add update-release-info (#5643) 2022-05-18 16:17:29 -07:00
stuartmorgan
4cecb9b264 [flutter_plugin_tools] Adds update-excerpts command (#5339) 2022-04-28 09:34:11 -07:00
David Iglesias
b532e1233b [tool] Fix typo in publish-plugin readme (#5107) 2022-03-24 15:35:09 -07:00
Ian Hickson
0f71f1755b [webview_flutter] Remove dependency on flutter.dev and google.com (#4691) 2022-01-25 13:10:21 -08:00
stuartmorgan
3de67cea56 [flutter_plugin_tools] Improve package targeting (#4577)
Improve package targeting:
- `--run-on-changed-packages` now includes only changed packages in a federated plugin, not all packages. Include all packages isn't useful since (without changes that would cause them to be included anyway) package dependencies are not path-based between packages.
- `--packages` now allows specifying package names of federated plugins. E.g., `--packages=path_provider_ios` will now work, instead of requiring `--packages=path_provider/path_provider_ios`. The fully qualified form still works as well (and is still needed for app-facing packages to disambiguate from the plugin group).

Fixes https://github.com/flutter/flutter/issues/94618
2021-12-07 07:02:24 -08:00
stuartmorgan
97178aff85 [flutter_plugin_tools] Replace xctest and java-test with native-test (#4176)
Creates a new `native-test` command that will be used to run native unit and UI/integration tests for all platforms over time. This replaces both `xctest` and `java-test`.

For CI we can continue to run each platform separately for clarity, but the combined command makes it easier to use (and remember how to use) for local development, as well as avoiding the need to introduce several new commands for desktop testing as support for that is added to the tool.

Fixes https://github.com/flutter/flutter/issues/84392
Fixes https://github.com/flutter/flutter/issues/86489
2021-07-22 11:14:17 -07:00
stuartmorgan
b7ff215760 [flutter_plugin_tools] Add --packages, and deprecated --plugins (#4134)
Most of the tool operates on packages in general, and the targetting
done currently by the `--plugins` flag is not actually restricted to
plugins, so this makes the name less confusing.

Part of https://github.com/flutter/flutter/issues/83413
2021-07-04 09:26:28 -07:00
stuartmorgan
f0967e5186 Update tool commands (#4065)
Update CI and README to call the tool via bin/flutter_plugin_tools.dart
rather than lib/src/main.dart to avoid a warning line on every run.
2021-06-17 21:23:51 -04:00
stuartmorgan
cb92e5d416 Enable macOS XCTest support (#4043)
- Adds macOS support to the `xctest` tool command
- Adds logic to the tool to check for packages that delegate their implementations
  to another package, so they can be skipped when running native unit tests
  - Updates the tool's unit test utility for writing pubspecs to be able to make
    delegated federated implementation references to test it
- Adds initial unit tests to the non-deprecated macOS plugins
- Enables macOS XCTesting in CI

macOS portion of https://github.com/flutter/flutter/issues/82445
2021-06-10 17:50:20 -04:00
stuartmorgan
d491b95e69 [flutter_plugin_tools] Remove xctest's --skip (#4022) 2021-06-07 11:29:07 -07:00
Rene Floor
9c15a2b4ce Some small documentation fixes (#3999)
* Two small documentation fixes

* Fix url to plugin_tool format
2021-06-02 17:40:17 +02:00
stuartmorgan
e46aa5583f Update tool README for packages use (#3882)
Updates to better reflect that this tooling is still used in flutter/packages, and how that differs from the flutter/plugins usage.
2021-05-14 20:03:23 -04:00
stuartmorgan
fe6b847932 Prep the tools for publishing (#3836)
Re-adds the LICENSE and CHANGELOG, and updates the README and pubspec,
in preparation for pushing an updated version of the package.

We are still using flutter_plugin_tools in flutter/packages, so this
allows us to use updates (e.g., license checks, fixed version checks) in
that repository as well. The README has been updated to note that it is
no longer intended for general use, and we will (if it allows
publishing) continue to mark the package as discontinued to reflect
that.
2021-04-29 20:05:38 -07:00
Chris Yang
63d42fcdb9 Update PULL_REQUEST_TEMPLATE.md (#3801) 2021-04-20 04:24:02 -07:00
Emmanuel Garcia
d3b50950ba Move plugin tools code (#3544) 2021-02-12 13:46:44 -08:00