- Don't assume different shell init scripts exist (bug #530770)

This commit is contained in:
Orion Poplawski 2009-10-26 17:01:51 +00:00
parent a163fccc9e
commit 27243c7396
2 changed files with 11 additions and 2 deletions

View File

@ -1,6 +1,6 @@
Name: environment-modules
Version: 3.2.7b
Release: 4%{?dist}
Release: 5%{?dist}
Summary: Provides dynamic modification of a user's environment
Group: System Environment/Base
@ -78,6 +78,9 @@ rm -rf $RPM_BUILD_ROOT
%changelog
* Mon Oct 26 2009 Orion Poplawski <orion@cora.nwra.com> - 3.2.7b-5
- Don't assume different shell init scripts exist (bug #530770)
* Fri Oct 23 2009 Orion Poplawski <orion@cora.nwra.com> - 3.2.7b-4
- Don't load bash init script when bash is running as "sh" (bug #529745)

View File

@ -1 +1,7 @@
. /usr/share/Modules/init/`basename \`ps -p $$ -ocomm=\``
shell=`/bin/basename \`/bin/ps -p $$ -ocomm=\``
if [ -f /usr/share/Modules/init/$shell ]
then
. /usr/share/Modules/init/$shell
else
. /usr/share/Modules/init/sh
fi