dotnet / dotnet/project-system
In VisualStudio, I can't add a new class in a project with OutputPath equals to '.'
- Dominant language
- C#
- Stars
- 1k
- Forks
- 415
- PR merge metrics
- No merged PRs in 30d
Description
**Visual Studio Version**:
VS2017, VS2019 and VS2022.
**Summary**:
I got an error if I add a new class in a project with `OutputPath` equals to '.'.
**Steps to Reproduce**:
1. Create a new csproj (like a ConsoleApp.csproj)
2. Add `.` at main property group.
3. Add a new class.
**Expected Behavior**:
Class should be added without errors.
**Actual Behavior**:
Class added with this error.
```
NETSDK1022 Duplicate 'Compile' items were included. The .NET SDK includes 'Compile' items from your project directory by default. You can either remove these items from your project file, or set the 'EnableDefaultCompileItems' property to 'false' if you want to explicitly include them in your project file.
```
**User Impact**:
I have to change output path.
Contributor guide
Assessment
This issue has not been assessed yet.