dlang / dub

Package and build management system for D
MIT License
677 stars 227 forks source link

Trying to run a library should fail fast #2735

Open snprajwal opened 11 months ago

snprajwal commented 11 months ago

When we try to run a library with dub run, the project is first built, and then errors out saying it is a library.

https://github.com/dlang/dub/blob/13ee9ce38a1c665baefc3bc84cceee27984f5d8a/source/dub/generators/build.d#L697-L699

Would it be better for this to happen right off the bat when the command is executed, and not waste time building the project?