Skip to content
Snippets Groups Projects
Commit bd763c2b authored by mark's avatar mark
Browse files

STYLE: use hard-coded user resource directory name for foamEtcFile

- previously used the value of $WM_PROJECT, but this is potentially
  inconsistent with what Foam::etcFiles uses.
parent 3a4038b2
No related branches found
No related tags found
1 merge request!121Merge develop into master for v1706 release
...@@ -120,9 +120,8 @@ then ...@@ -120,9 +120,8 @@ then
fi fi
projectDirName="${projectDir##*/}" # The project directory name projectDirName="${projectDir##*/}" # The project directory name
projectName="${WM_PROJECT:-OpenFOAM}" # The project name
projectVersion="$WM_PROJECT_VERSION" # Empty? - will be treated later projectVersion="$WM_PROJECT_VERSION" # Empty? - will be treated later
userDir="$HOME/.OpenFOAM" # Hard-coded as per foamVersion.H
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
...@@ -290,9 +289,9 @@ fi ...@@ -290,9 +289,9 @@ fi
# Updates: # Updates:
# - projectDir for changes via -prefix or -version # - projectDir for changes via -prefix or -version
# - projectSite for changes via -prefix # - groupDir for changes via -prefix
projectDir="$prefixDir/$projectDirName" projectDir="$prefixDir/$projectDirName"
projectSite="${WM_PROJECT_SITE:-$prefixDir/site}" groupDir="${WM_PROJECT_SITE:-$prefixDir/site}"
# Debugging: # Debugging:
...@@ -311,12 +310,12 @@ fileName="${1#~OpenFOAM/}" ...@@ -311,12 +310,12 @@ fileName="${1#~OpenFOAM/}"
# Define the various places to be searched: # Define the various places to be searched:
unset dirList unset dirList
case "$optMode" in (*u*) # (U)ser case "$optMode" in (*u*) # (U)ser
dirList="$dirList $HOME/.$projectName/$projectVersion $HOME/.$projectName" dirList="$dirList $userDir/$projectVersion $userDir"
;; ;;
esac esac
case "$optMode" in (*g*) # (G)roup == site case "$optMode" in (*g*) # (G)roup == site
dirList="$dirList $projectSite/$projectVersion $projectSite" dirList="$dirList $groupDir/$projectVersion $groupDir"
;; ;;
esac esac
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment