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

--collapsefolders = true not working for single sub-folders #505

Closed
wdcossey opened this issue Aug 10, 2023 · 2 comments · Fixed by #515
Closed

--collapsefolders = true not working for single sub-folders #505

wdcossey opened this issue Aug 10, 2023 · 2 comments · Fixed by #515

Comments

@wdcossey
Copy link

I have an issue where --collapsefolders:true generates a .sln file that can't be loaded by Visual Studio (2022), it does work in Rider (just about).

The issue only happens when there's a single folder

- root
  - core
    - Project A
      - src
    - Project B
      - src
  - interface
    - Project C
      - src

slngen will generate the first folder core fine but the other interface will fail, as it tries to generate a solution folder with an invalid name

Example:

Project("{}") = "interface / Project C", "root\interface", "{}"
@michael-hawker
Copy link
Contributor

Is this the same as #438?

@glards
Copy link

glards commented Sep 4, 2023

I experienced the same issue today. After investigating, it seems to be a regression from #495 in v10.2.0. I got around it by downgrading the tool to v10.0.0.

The root cause is that the separator for folder name was changed to '/' which causes Visual Studio to not load the projects under the folders with the following error:

Solution Folder names cannot:

  • contain any of the following characters: / ? : \ * "" < > |
  • contain Unicode control characters
  • contain surrogate characters
  • be system reserved names, including 'CON', 'AUX', 'PRN', 'COM1' or 'LPT2'
  • be '.' or '..'

The previous code was using character '\u0338'.

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 a pull request may close this issue.

3 participants