-
Notifications
You must be signed in to change notification settings - Fork 16
fix script to init EESSI for csh shells, fixes also the CI for csh and speeds up CI
#102
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
Merged
Merged
Changes from all commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
3e8d2fe
also test init for csh
truib fbd2689
install (t)csh too
truib 5120a61
format csh file to follow syntax + 4 spaces indentation
truib a952a16
use backticks in csh + some polishing
truib 5b5bc10
avoid some apt triggers
truib 0b914fd
ensure trigger for man-db is not triggered earlier
truib b15b4f7
(t)csh uses slightly different shell redirection syntax
truib b56da62
using module alias in non-interactive csh is a little tricky
truib c315cdc
fix syntax glitch
truib 05016f6
show test script to be run
truib e4fa51d
create, cat and test .cshrc in HOME dir
truib 56cb0d7
use csh workaround for other tests
truib 90f3e8d
discard some error messages + use here-string in last test too
truib bb8ac18
fix stderr redirection for .cshrc
truib 056d6be
clean up some debug output and add new for test 4
truib 0c60458
fix string quoting
truib a9c5dc3
discard output when loading EasyBuild
truib cac1100
try running in non-login shell
truib 5b93cd8
clean up some debug output and rearrange output processing
truib 9da3863
replacing tabs with spaces and final polishing/cleanup
truib 40bc520
don't need to show workflow file
truib File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @trz42 it seems you are way more talented than me, to handle csh error message. After all the "Illegal variable name." and "then: then/endif not found" error messages, I am happy to see this script finally working correctly. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,19 +1,24 @@ | ||
| # Choose an EESSI CVMFS repository | ||
| if (! $?EESSI_CVMFS_REPO) then; set EESSI_CVMFS_REPO = "/cvmfs/software.eessi.io"; endif | ||
| if (! $?EESSI_CVMFS_REPO) then | ||
| set EESSI_CVMFS_REPO = "/cvmfs/software.eessi.io" | ||
| endif | ||
| # Choose an EESSI version | ||
| setenv EESSI_VERSION_DEFAULT "__EESSI_VERSION_DEFAULT__" | ||
| if (! $?EESSI_VERSION) then; set EESSI_VERSION = "${EESSI_VERSION_DEFAULT}"; endif | ||
| if (! $?EESSI_VERSION) then | ||
| set EESSI_VERSION = "${EESSI_VERSION_DEFAULT}" | ||
| endif | ||
| # Path to top-level module tree | ||
| setenv MODULEPATH "${EESSI_CVMFS_REPO}/versions/${EESSI_VERSION}/init/modules" | ||
| source "${EESSI_CVMFS_REPO}/versions/${EESSI_VERSION}/compat/linux/$(uname -m)/usr/share/Lmod/init/csh" | ||
| source "${EESSI_CVMFS_REPO}/versions/${EESSI_VERSION}/compat/linux/`uname -m`/usr/share/Lmod/init/csh" | ||
|
|
||
| if (! $?__Init_Default_Modules ) then | ||
| setenv __Init_Default_Modules 1; | ||
| setenv __Init_Default_Modules 1 | ||
|
|
||
| ## ability to predefine elsewhere the default list | ||
| if (! $?LMOD_SYSTEM_DEFAULT_MODULES) then; setenv LMOD_SYSTEM_DEFAULT_MODULES "EESSI/$EESSI_VERSION"; endif | ||
| module --initial_load --no_redirect restore | ||
| # ability to predefine elsewhere the default list | ||
| if (! $?LMOD_SYSTEM_DEFAULT_MODULES) then | ||
| setenv LMOD_SYSTEM_DEFAULT_MODULES "EESSI/${EESSI_VERSION}" | ||
| endif | ||
| module --initial_load --no_redirect restore | ||
| else | ||
| module refresh | ||
| module refresh | ||
| endif | ||
|
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is good, I'm going to steal this for the EESSI GitHub Action
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the slow-down caused by the
sudo apt install zsh ksh fish tcshbelow?Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's a general thing, slow is relative, it typically 20-30 second for updating
man-db, which we will never use so might as well disable it.