-
Notifications
You must be signed in to change notification settings - Fork 4.9k
Conversation
The developer documentation at https://github.com/dotnet/corefx/blob/master/Documentation/project-docs/developer-guide.md#building-individual-projects says to get a recent If the steps in the official developer documentation do not work, we should update them as appropriate; not just add a little hard to discover script. |
I get this error while running on mac
I get this error while running on unix
But while running .dotnet/dotnet msbuild src/System.IO.FileSystem/src/ /t:rebuild I will change the documentation |
Earlier we used to use the Tools\DotnetCliVersion\dotnet if the dotnet is not present in the PATH Variable but now we have moved that dotnet to .\dotnet\dotnet. I think the dotnet msbuild individualproject will still work if have appropriate version of dotnet installed on our system |
We had a long discussion about this in #30919 (comment) . The agreement in that discussion was that we want to make a regular global Now, I know that the corefx developer experience is not as good as it used to be after upgrading to Arcade. It has rough edges. dotnet/arcade#1364 is the worst offender for me. It would be better to fix the rough edges instead of introducing workarounds for them. |
Does that mean a "razzle like" batch file that adds it to the path? I don't object, but if that's the plan @Anipik can add that, instead? |
Having a small helper bat/sh script that adds the local dotnet to the path - if you do not have one globally installed and you do not want to install one - sounds good to me. Also, mention it in the developer guide. |
These are transient errors that should go away after a clean build.
You didn't install dotnet correctly. Works on my Ubuntu machine.
We can add that if necessary, but is it really necessary? Why not use the globally installed dotnet sdk which works fine? |
Not talking about the points that we already discussed in the past (like mixing dotnet installations, global vs repo one) but the last month showed that for a dev flow the globally installed one works just fine. |
Why not just calling eng/common/msbuild.sh and passing the parameters along? That one already makes sure dotnet is installed, if not it boostraps it for you and calls the one from the right location. |
I am running on a docker machine and I haven't installed globally. I can try with that. It will be helpful to have some mechanism to use the sdk from corefx repo without installying globally. |
I prefer typing |
I was speaking from the script he is adding. So msbuild.sh from the root just being a wrapper of the one in eng common. |
I still don't understand what's the purpose of adding a razzle like script over using the globally installed sdk? The only pro is that we don't mix dotnet installations when building from root vs individual projects but as already stated that scenario has been working fine for me and others for the last months so I don't see why we are changing this now? |
If I build from a VS developer prompt, |
Having VS installed won't be a requirement in the future anymore (dotnet/arcade#64) hence we probably want to have two scripts for both Unix and Windows. I'm not sure which workflow we should advertise in our docs as the majority of users will have dotnet installed globally anyway. |
I think having an msbuild.sh/cmd script that just calls the underlying eng/common/msbuild.ps1(sh) script sounds like a reasonable thing to have as people might find shorter and easier to write Also, we could add an msbuild switch to the build scripts in the root if we don't wan to add more scripts to our repo root. Something like |
build.cmd can do this already. You do not even have to specify |
This doesn't work great to build an individual project, as what it does is call the arcade build.ps1 script, which calls msbuild on build.proj inside arcade SDK, and then call the passed project (Plus we will always call -restore and restore the buildtools) which we only want to do once. Also, it doesn't work great with msbuild parameters, so we should fix that if we want to encourage people using that to build a single project. Running
|
Yep, the documented developer experience has number of rough edges after the Arcade migration. My meta-point is that we need to make the documented developer experience to work well - by fixing both the docs and/or the scripts. |
What's the status of this? Can/should this be closed? |
I think based on the discussion this can be closed as @ViktorHofer submitted a fix to make build.sh/cmd with individual projects work as expected. Plus we already have eng/common/msbuild.sh -- and the Tools directory will go away soon once we completely delete buildtools which we're close enough to achieve. So the only msbuild.sh script will be under eng/common which already does the right thing. |
Currently we are making this file on the run and we are using the path to dotnet as Tools/dotnetcli/dotnet which no longer exists and we are not able to run the tests individually for the projects
The latest path to dotnet is from the root only i.e ./dotnet/dotnet
before
after