-
Notifications
You must be signed in to change notification settings - Fork 675
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
Need to add "Compile Include ..." to use files generated during the build but this causes more errors #1822
Comments
Many thanks for the detailed repro! I can definitely reproduce with this project. |
Thanks again for the repro project. I have found the cause of the issue. We are failing to set the You can workaround this problem by setting
No errors! |
OK. I have a fixed checked into OmniSharp to address this issue. It turned out to not be the same root cause as #1531, so I appreciate you taking the time to file this with an excellent repro. Once we take a new release of OmniSharp into C# for VS Code, I'll close this issue. |
I confirm this works when the files are already in obj, created by But if I clean obj, should OmniSharp also cause the files to be generated? Currently it is not. |
It won't generate the files simply by passing that variable, but it will with my full OmniSharp change. The project needs to be restored first though. There is an issue in OmniSharp where it won't reload a project after a restore in some cases (and this is one of them). However, if the project is already restored, the files will be generated when OmniSharp loads the project. I just tried this to verify. |
@asfernandes : I just wanted to let you know that I just released on a new beta of C# for VS Code that fixes this issue: 1.3.0-beta5. You can following these instructions if you're interested in trying it out. |
Seems working. It does not update generated files automatically when I save .g4 files, but it updates when I run the build target in vscode. |
Correct. It will only regenerate the files when MSBuild runs. That happens on initial project loading and during build. |
Environment data
dotnet --info
output:VS Code version: 1.17.0
C# Extension version: 1.12.0 (I think)
Steps to reproduce
The attached project uses
<Compile Include="$(IntermediateOutputPath)\*.cs" />
soGrammarParser
is recognized. But usage ofCompile
causes others problems in Problems view and with dotnet cli.If I remove
Compile
the project builds correctly with dotnet cli, but then OmniSharp does not recognizeGrammarParser
.The text was updated successfully, but these errors were encountered: