From 0eae457cdbe1249559b108ed3064780ddd4e8b2c Mon Sep 17 00:00:00 2001 From: Sam Clegg Date: Thu, 17 Jun 2021 10:36:50 -0700 Subject: [PATCH] Point zsh and csh users to the correct startup script (#843) Fixes: https://github.com/emscripten-core/emscripten/issues/14446 --- emsdk.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/emsdk.py b/emsdk.py index 4c597d0..7eea73d 100644 --- a/emsdk.py +++ b/emsdk.py @@ -1663,8 +1663,14 @@ JS_ENGINES = [NODE_JS] print(' ' + p) print('- This can be done for the current shell by running:') print(' source "%s"' % emsdk_env) - print('- Configure emsdk in your bash profile by running:') - print(' echo \'source "%s"\' >> $HOME/.bash_profile' % emsdk_env) + print('- Configure emsdk in your shell startup scripts by running:') + shell = os.environ.get('SHELL', '') + if 'zsh' in shell: + print(' echo \'source "%s"\' >> $HOME/.zprofile' % emsdk_env) + elif 'csh' in shell: + print(' echo \'source "%s"\' >> $HOME/.cshrc' % emsdk_env) + else: + print(' echo \'source "%s"\' >> $HOME/.bash_profile' % emsdk_env) def find_msbuild_dir():