It's all about the answers!

Ask a question

scm does not respect $HOME variable for .jazz-scm folder?


Eric Benzacar (41912) | asked Nov 10 '15, 3:56 p.m.
I'm trying to move my .jazz-scm folder from home $HOME folder to some other folder that I have specified.  However, scm.sh does not seem to respect it.

--config ]  path
The Rational Team Concert source control command line client stores per-user metadata in a configuration directory. The configuration directory is normally $HOME/.jazz-scm, where $HOME represents your home directory. If you want to use a different configuration directory, specify its path name in path .


However, when I try the following:
# export HOME=/home/eric/jbe
# scm login  --repository-uri https://scm.ngf.local/ccm --username eric

it still creates my .jazz-scm folder under /home/eric and not /home/eric/jbe!

Is it not $HOME that it is using?  Should I be setting a different environment variable instead?

Thanks,

Eric

One answer



permanent link
Kevin Ramer (4.5k8183200) | answered Nov 10 '15, 4:25 p.m.
edited Nov 10 '15, 5:02 p.m.
In Java Land home is the property user.home  (e.g.  java -Duser.home ..... ).  Plus, HOME should be treated as read-only as setting it may have no effect or certainly not the desired effect.    I'm going to wager that the java is taking the value of user.home if --config is not specified.

I ran strace on an scm login command.  There is no call to getenv of any variety and if I redefine HOME as you have found no scm data is written there.   Using --config with explicit path works.    


Comments
Eric Benzacar commented Nov 11 '15, 12:49 a.m.

I was afraid that might be happening.  I was hoping to find an environment variable to control the location of the .jazz-scm directory as modifying the parameters passed to scm is quite difficult, so passing the --config <path> parameter is not as simple as you might expect.



Shashikant Padur commented Nov 17 '15, 12:02 a.m.
JAZZ DEVELOPER

You can either specify --config or you can set the environment variable SCM_CONFIG_DIRECTORY. Here is the link to the list of environment variables: https://jazz.net/help-dev/clm/index.jsp?re=1&topic=/com.ibm.team.scm.doc/topics/c_scm_cli_env_var.html&scope=null

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.