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

Exclude GNU Screen environmental variables in pass_env #66

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions pass_env
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
#!/bin/bash

# AJVincelli 3/8/2021: Excluded TERMCAP and its tabbed ($'\t') variables, which causes Launcher to fail when using GNU Screen on some clusters

#EXCLUDE is a list of patterns that should be removed from the environment before passing to launcher tasks on remote hosts
EXCLUDE="BASH_FUNC ModuleTable LS_ LESS SSH_ PE_MPICH MINICOM SLURM_NODELIST SLURM_JOB_NODELIST PS1 PROMPT_"
EXCLUDE="BASH_FUNC ModuleTable LS_ LESS SSH_ PE_MPICH MINICOM SLURM_NODELIST SLURM_JOB_NODELIST PS1 PROMPT_ TERMCAP"

GREP_ARGS=`
for prefix in $EXCLUDE
Expand All @@ -10,4 +12,4 @@ GREP_ARGS=`
done
`

env | grep -v -e "}$" -e "^ " -e "=$" -e "^_" -e "(" $GREP_ARGS | grep -v -e " " | tr '\n' ' '
env | grep -v -e "}$" -e "^ " -e "=$" -e "^_" -e "(" -e $'\t' $GREP_ARGS | grep -v -e " " | tr '\n' ' '