[Qbs] Passing paths to properties
Christian.Kandeler at qt.io
Mon Feb 3 13:37:20 CET 2020
On Sat, 1 Feb 2020 09:30:33 +0100
Richard Weickelt <richard at weickelt.de> wrote:
> > I believe that most other properies which accept a path (like installDir,
> > and the prefix property within a Group) all happily accept a relative
> > path, so can we consider this a bug in Android.sdk?
> You mean qbs.installDir? That is - by definition - relative to qbs.installRoot.
> > Also, while thinking about a solution to this, I was thinking that a
> > resolvePath() method in the FileInfo service could be useful:
> > var path = ... // absolute or relative var absolutePath =
> > FileInfo.resolvePath(path, basePath);
> > which would return path, if it's already absolute, or join it with
> > basePath if path is relative.
> > Would this be a useful addition, or do we already have something like
> > this in QBS?
> This and in addition - since the documentation already calls the property a
> "path"  - introduce a path property type in Qbs which does that
> automatically for us in its toString() method.
More information about the Qbs