Skip to content

Document the dart migrate command-line tool - #7584

Merged
conooi merged 10 commits into
dart-lang:mainfrom
conooi:dart-migrate
Nov 4, 2026
Merged

conooi merged 10 commits into
dart-lang:mainfrom
conooi:dart-migrate

Conversation

@conooi

@conooi conooi commented Oct 29, 2026

Copy link
Copy Markdown
Contributor

Adds documentation for the dart migrate command-line tool introduced in Dart 3.14:

  • Adds a new /tools/dart-migrate guide (src/content/tools/dart-migrate.md) covering:
    • How to preview (--dry-run) and apply (--apply) package migrations
    • How the migration workflow operates (prepare, bump, and optional cleanup steps) and handles failures
    • Command-line options (--help, --dry-run, --apply, --target-sdk, and --step)
    • A before-and-after example migrating from Dart 3.12 to 3.13
    • When to use dart migrate vs. dart fix
  • Adds dart migrate to the Command-line tools > Dart SDK sidenav (src/data/sidenav/default.yml).
  • Adds migrate to the available commands table on /tools/dart-tool (src/content/tools/dart-tool.md).

@dart-github-bot

dart-github-bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Collaborator

@conooi
conooi marked this pull request as ready for review October 30, 2026 18:19

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces documentation for the new dart migrate command-line tool, including adding a new markdown file dart-migrate.md, updating the dart-tool.md command reference table, and adding the command to the sidebar navigation. The review feedback points out an inaccuracy in the migration example, noting that using final on regular function parameters is valid in Dart and does not cause a compile-time error in Dart 3.13, and suggests replacing it with an actual breaking change.

Comment thread src/content/tools/dart-migrate.md Resolved
@conooi
conooi requested a review from kallentu October 30, 2026 18:20
Comment thread src/content/tools/dart-migrate.md Resolved
Comment thread src/content/tools/dart-migrate.md Resolved
Comment thread src/content/tools/dart-migrate.md Resolved
Comment thread src/content/tools/dart-migrate.md Resolved
Comment thread src/content/tools/dart-migrate.md Resolved
Comment thread src/content/tools/dart-migrate.md Resolved
@conooi
conooi requested a review from kallentu November 3, 2026 00:30

@kallentu kallentu left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

Comment thread src/content/tools/dart-migrate.md Resolved

@sfshaza2 sfshaza2 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@conooi
conooi merged commit 0e1d988 into dart-lang:main Nov 4, 2026
17 checks passed
@conooi
conooi deleted the dart-migrate branch November 4, 2026 18:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants