Project root relative paths
Posted: Tue Apr 21, 2015 10:56 am
We have a large project that is split into several files. Is it possible to include files through paths that are relative to the project root directory (i.e not relative to the current file)?
For example:
Is there a way to reference file1 from file2 by saying "a/file1.xml" (relative to the project) instead of "../a/file1.xml" (relative to the file2.xml file) ?
Our current solution is to define an entity "projectRoot" which has the absolute path of the project directory. All other paths are then resolved based on the "projectRoot" entity. This is bad because it is not portable across users and operating systems.
For example:
Code: Select all
root
a
file1.xml
b
file2.xml
Our current solution is to define an entity "projectRoot" which has the absolute path of the project directory. All other paths are then resolved based on the "projectRoot" entity. This is bad because it is not portable across users and operating systems.