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

NCCS: output directory wants .cs extensions #798

Open
cschuchardt88 opened this issue Oct 5, 2023 · 0 comments
Open

NCCS: output directory wants .cs extensions #798

cschuchardt88 opened this issue Oct 5, 2023 · 0 comments

Comments

@cschuchardt88
Copy link
Member

cschuchardt88 commented Oct 5, 2023

Running command dotnet nccs "CallContract.csproj" -o "sc" gives error The files must have a .cs extension. But if you put full path error goes away. If you need full path for it to work, than the help should say so.

Visual Studio build command

<Target Name="PostBuild" AfterTargets="PostBuildEvent">
  <Exec WorkingDirectory="$(SolutionDir)" Command="dotnet nccs &quot;$(MSBuildProjectFile)&quot; -o &quot;sc&quot;" />
</Target>

Output

1>  Task "Exec"
1>    dotnet nccs "CallContract.csproj" -o "sc"
1>    The files must have a .cs extension.
1>    C:\Users\Chris\Projects\cschuchardt88\neo-examples-csharp\src\CallContract\CallContract.csproj(9,5): error MSB3073: The command "dotnet nccs "CallContract.csproj" -o "sc"" exited with code 1.
1>  Done executing task "Exec" -- FAILED.

Workaround

dotnet nccs "CallContract.csproj" -o "C:\Users\Chris\Projects\cschuchardt88\neo-examples-csharp\sc"

Visual Studio build command

<Target Name="PostBuild" AfterTargets="PostBuildEvent">
  <Exec Command="dotnet nccs &quot;$(MSBuildProjectFile)&quot; -o &quot;$(SolutionDir)sc&quot;" />
</Target>

Output

1>Target PostBuild:
1>  Task "Exec"
1>    dotnet nccs "CallContract.csproj" -o "C:\Users\Chris\Projects\cschuchardt88\neo-examples-csharp\sc"
1>      Determining projects to restore...
1>      All projects are up-to-date for restore.
1>    Created C:\Users\Chris\Projects\cschuchardt88\neo-examples-csharp\sc\CallContract.nef
1>    Created C:\Users\Chris\Projects\cschuchardt88\neo-examples-csharp\sc\CallContract.manifest.json
1>    Compilation completed successfully.
1>  Done executing task "Exec".
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

No branches or pull requests

1 participant