Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Environment variable initialized with setenv are not correctly appended later in modulefile #342

Closed
xdelaruelle opened this issue May 9, 2020 · 0 comments
Labels
Milestone

Comments

@xdelaruelle
Copy link
Member

Describe the bug

When defining an environment variable with setenv in a modulefile, if this variable value is later in the modulefile appended (with append Tcl command), initial value set with setenv has disappeared.

To Reproduce

Steps to reproduce the behavior:

With the following mod modulefile:

$ cat mod
#%Module
setenv FOO foo
setenv BAR $env(FOO)
append env(BAR) bar

Load this modulefile then check value of BAR variable:

$ ml -v ./mod
Loading /path/to/mod
$ echo $BAR
bar

Expected behavior

Resulting BAR environment variable should equal to foobar not bar, as it is first initialized with foo value.

@xdelaruelle xdelaruelle added the bug label May 9, 2020
@xdelaruelle xdelaruelle added this to the 4.5.1 milestone May 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant