-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Copy flutter.bat before execution #20554
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
Conversation
|
/cc @timsneath @aam |
|
Can we put it in |
bin/flutter.bat
Outdated
| REM -------------------------------------------------------------------------- | ||
|
|
||
| REM Execute a copy of the script to prevent modifications to a running script, | ||
| REM see https://github.com/flutter/flutter/issues/14578 for details. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think you need the reference to the bug, just say something like "(as might happen during an upgrade)" or some such.
Initially I wanted to avoid that because it adds more complexity to this delicate script (what if cache doesn't exist yet? Now the original script and the copied version have different parent directories. etc.) However, thinking about this more I am going to re-work this and break the script up into two scripts: one flutter.bat which is a wrapper that just copies a to-be-created script from bin/internal to bin/cache and then executes it. The new script will then do the heavy lifting of initializing flutter. |
|
I made the changes as described above. PTAL |
bin/internal/run_flutter.bat
Outdated
| REM ---------------------------------- NOTE ---------------------------------- | ||
| REM | ||
| REM Please keep the logic in this file consistent with the logic in the | ||
| REM `flutter` script in the same directory to ensure that Flutter continues to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nits: flutter script is no longer in the same directory.
Also, https://github.com/flutter/flutter/blob/master/bin/flutter#L10 needs to be adjusted to point to bin/internal/run_flutter.bat now.
aam
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Still lgtm, even though it's a little sad to see similarity between bin/fluttter and bin/flutter.bat lost(with bin/flutter.bat split into two).
This reverts commit 28bc818.
Fixes #14578