Am 07.05.2014 12:12, schrieb Andrej Mitrovic:
On Wed, 07 May 2014 06:56:59 GMT, Sönke Ludwig wrote:
When they are sub packages, they can be compiled as
dub root-pack:tutor1
*. When they are free standing packages, indeed eithercd path/to/example && dub
is necessary, ordub --root=path/to/example
.I guess this is ok since the user might want to be able to run
dub
when they're inside a sample directory.* New feature planned for the next release: Allow
dub :tutor1
to be used to refer to sub packages.That would be nice! A related feature I kind of want is the ability to write aliases so I can write things like:
"aliases:": { "tut01": "opengl-tutorial.org:tut01", },
And then run:
dub run tut01
Aliases might be a good feature for other things, e.g. if you want to rename things but want to keep backward compatibility for a while (I guess emitting a deprecation message would also be appropriate if an alias is marked as deprecated).
Okay, for now the :tut01 syntax works. I'm not yet sure what the
possible caveats of a general alias feature would be (conflicts etc.).
Package deprecation could also be done by keeping a dummy target type
"none" package that just has the new dependency name as the only dependency.