Open rracariu opened 6 years ago
what is what you call "the shebang trick" ? embedded receipt ?
Yes. The embedded reciept.
Can you describe your use case a bit more ?
It seems very rare that one would want to add dependencies just for one dub run. And even if that happens, dub add pkg@version && dub run ... && dub remove pkg
could easily be made an alias.
Currently in order to test a random dub package one needs to either create a dummy
dub
package that includes the test package as a dependency or could use the shebang trick.Both have downside, first is more involved as it requires creating an additional file and basic knowledge of the dub format. The second is very Unix-ish and not something Windows users are familiar with and usually hard to translate to a Windows environment.
My RFE is a command line option, lets call it
--deps
, that allows one to specify a list ofpackage name - version
tuple, something akin todub --deps vibe-d ~>0.8, libasync
The list of
package name - version
tuple is specified asA dependency can omit the version requirements, this will default to
latest
When
--deps
is useddub
should automatically compile all*.d
files in the current directory and assume anapplication
type.This will greatly improve the experience for new comers and make life easy for savvy developers looking to quickly test some code in combination with some dub packages.