Skip to content

Conversation

@stuartmorgan-g
Copy link
Contributor

Uses the correct generator string when a VS 2022 installation is
detected.

Part of #85922

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.

Uses the correct generator string when a VS 2022 installation is
detected.

Part of flutter#85922
@flutter-dashboard flutter-dashboard bot added the tool Affects the "flutter" command-line tool. See also t: labels. label Nov 10, 2021
@google-cla google-cla bot added the cla: yes label Nov 10, 2021
@stuartmorgan-g
Copy link
Contributor Author

@cbracken Your call on when you want to land this relative to CI changes to get e2e testing with it, but this should be all the tool actually needs changed.

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.

lgtm -- thanks!

const String visualStudioPath = r'C:\Program Files (x86)\Microsoft Visual Studio\2017\Community';
const String cmakePath = visualStudioPath + r'\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\cmake.exe';
const String _cmakePath = visualStudioPath + r'\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\cmake.exe';
const String _defaultGenerator = 'Visual Studio 16 2019';
Copy link
Member

Choose a reason for hiding this comment

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

Any reason for making these library-private, given it's a test?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

cmakePath as a default value for the named cmakePath parameter didn't work, and this seemed like a trivial way to disambiguate.

@cbracken
Copy link
Member

I think it's fine to land this as-is. Once the infra work is complete, we'll enable the build tests with VS2022.

@Cagatay342
Copy link

i tired it as windows app . it worked but , as uwp i couldnt run it. it shows uwp in "flutter devices" but when "flutter run" doesnt show uwp as device

@Cagatay342
Copy link

i tired it as windows app . it worked but , as uwp i couldnt run it. it shows uwp in "flutter devices" but when "flutter run" doesnt show uwp as device

solved :) it was existed project. i run "flutter create ." and it created uwp folders and it worked

@stuartmorgan-g stuartmorgan-g deleted the vs-2022-support branch November 17, 2021 23:51
@stuartmorgan-g
Copy link
Contributor Author

In the future please use issue trackers to report issues, not already-merged PRs.

WizzXu pushed a commit to WizzXu/flutter that referenced this pull request Nov 19, 2021
github-merge-queue bot pushed a commit that referenced this pull request Nov 1, 2025
Adds a mapping for Visual Studio 2026 to the `cmakeGenerator` property
used to drive Windows builds, enabling Flutter to be used for
development on a system with Visual Studio 2026 installed and not Visual
Studio 2022 or Visual Studio 2019.

Closes: #176399
Related-To: #93426

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [x] I followed the [breaking change policy] and added [Data Driven
Fixes] where supported.
- [x] All existing and new tests are passing.
flutteractionsbot pushed a commit to flutteractionsbot/flutter that referenced this pull request Nov 13, 2025
Adds a mapping for Visual Studio 2026 to the `cmakeGenerator` property
used to drive Windows builds, enabling Flutter to be used for
development on a system with Visual Studio 2026 installed and not Visual
Studio 2022 or Visual Studio 2019.

Closes: flutter#176399
Related-To: flutter#93426

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [x] I followed the [breaking change policy] and added [Data Driven
Fixes] where supported.
- [x] All existing and new tests are passing.
bufffun pushed a commit to bufffun/flutter that referenced this pull request Nov 26, 2025
Adds a mapping for Visual Studio 2026 to the `cmakeGenerator` property
used to drive Windows builds, enabling Flutter to be used for
development on a system with Visual Studio 2026 installed and not Visual
Studio 2022 or Visual Studio 2019.

Closes: flutter#176399
Related-To: flutter#93426

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [x] I followed the [breaking change policy] and added [Data Driven
Fixes] where supported.
- [x] All existing and new tests are passing.
reidbaker pushed a commit to AbdeMohlbi/flutter that referenced this pull request Dec 10, 2025
Adds a mapping for Visual Studio 2026 to the `cmakeGenerator` property
used to drive Windows builds, enabling Flutter to be used for
development on a system with Visual Studio 2026 installed and not Visual
Studio 2022 or Visual Studio 2019.

Closes: flutter#176399
Related-To: flutter#93426

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [x] I followed the [breaking change policy] and added [Data Driven
Fixes] where supported.
- [x] All existing and new tests are passing.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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.

4 participants