View Full Version : Using Environment Variables in a Directory in a File Action

06-03-2003, 06:41 PM
I am trying to specify a directory name in a files action using an environment variable. The directory structure may be different on the build machine, and I need to have the flexibility of using the env. variable.

Is there a way to specify a file or directory using an environment variable?

Mike Ryan
Stellent, Inc.

Jeff Dillon
06-03-2003, 09:29 PM
The ISMP solution to this problem is the "alias". The alias can be specified once and used then used for all files. You can also set aliases for a command line build.

Look up alias in the ISMP help system.

06-04-2003, 11:48 AM
Thanks, thats what I figured would be the response.

A few questions about Aliases, though:

Can I use one alias inside another alias? Say I have an alias that points to a particular build directory, say Z:\build13, can I then have two aliases that point to various directories under that directory?

For Example;

Additionally, if an alias is set in a project file, will it be overridden by an alias set on the command line?

Thanks again,

Mike Ryan
Stellent, Inc.

06-09-2003, 07:47 AM
Firstly, the alias value you set on the command line will override the one you have set in the project. (I don't think those aliases are actually at the project level, I believe they are at the IDE level so would apply to ALL projects.)

Secondly, I don't know specifically whether you can have nested environment variables as you describe, but you can set multiple aliases on the command line. Presuming you have a scipt to launch your build, you could use something like -alias a=foo -alias b=foo/bar etc, that shouldn't cause you too much hassle if your other idea doesn't work. (There's actually an alias.properties file in the root of ISMP installation, you could rewrite this file and specify it's location on the command line for your build as another alternative.)