Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Tool] [Windows] Output app path on build completion #122928

Merged
merged 2 commits into from Mar 20, 2023

Conversation

loic-sharma
Copy link
Member

@loic-sharma loic-sharma commented Mar 17, 2023

⚠️ This re-lands #122858 after it was reverted by #122926. The fix is c098e6f (#122928): it uses CMake's app name instead of pubspec.yaml's app name as these can get out of sync.

Improves the build output:

  1. Gives confirmation that the build succeeded
  2. Gives the path to the built executable

This matches the behavior of other Flutter platforms like Android.

Part of #120127

Flutter run

> flutter run -d windows
Launching lib\main.dart on Windows in debug mode...
Building Windows application...                                    11.1s
✓  Built build\windows\runner\Debug\x10.exe.
Syncing files to device Windows...                                  60ms

Flutter run key commands.
r Hot reload. 🔥🔥🔥
R Hot restart.
h List all available interactive commands.
d Detach (terminate "flutter run" but leave application running).
c Clear the screen
q Quit (terminate the application on the device).

Flutter build

> flutter build windows
Building Windows application...                                    25.9s
✓  Built build\windows\runner\Release\x10.exe (0.1MB).

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I read and followed the Flutter Style Guide, including Features we expect every widget to implement.
  • I signed the CLA.
  • I listed at least one issue that this PR fixes in the description above.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or this PR is test-exempt.
  • All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel on Discord.

@flutter-dashboard flutter-dashboard bot added team Infra upgrades, team productivity, code health, technical debt. See also team: labels. tool Affects the "flutter" command-line tool. See also t: labels. labels Mar 17, 2023
@@ -94,10 +94,11 @@ Future<void> buildWindows(WindowsProject windowsProject, BuildInfo buildInfo, {
status.stop();
}

final String? binaryName = getCmakeExecutableName(windowsProject);
Copy link
Member Author

Choose a reason for hiding this comment

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

This is the reland's fix. The original change used the app's name according to the pubspec.yaml file and assumed that matched CMake's app name. However, these files can get out of sync.

@loic-sharma loic-sharma marked this pull request as ready for review March 19, 2023 01:34
Copy link
Member

@christopherfujino christopherfujino left a comment

Choose a reason for hiding this comment

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

LGTM

@loic-sharma loic-sharma added the autosubmit Merge PR when tree becomes green via auto submit App label Mar 20, 2023
@auto-submit auto-submit bot merged commit 2312097 into flutter:master Mar 20, 2023
131 checks passed
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Mar 21, 2023
@loic-sharma loic-sharma deleted the windowds_output_exe branch March 21, 2023 18:59
Copy link
Member

@cbracken cbracken left a comment

Choose a reason for hiding this comment

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

🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
autosubmit Merge PR when tree becomes green via auto submit App team Infra upgrades, team productivity, code health, technical debt. See also team: labels. tool Affects the "flutter" command-line tool. See also t: labels.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants