Merge branch 'quote-vars' of https://github.com/rohanjoyce/intellij-community
authorDmitry Trofimov <dmitry.trofimov@jetbrains.com>
Mon, 22 Oct 2018 15:56:29 +0000 (17:56 +0200)
committerDmitry Trofimov <dmitry.trofimov@jetbrains.com>
Mon, 22 Oct 2018 15:56:29 +0000 (17:56 +0200)
1  2 
plugins/terminal/resources/jediterm-bash.in

index 29f4a5378d7dc4633c41288bb08b1cf4e9f6afa9,33ffde971fbef0675dd5def70cd4895866cc80f7..3ae5b405ed1da9063cf1cee875ffe8b04b9479c3
@@@ -31,23 -31,7 +31,23 @@@ function load_interactive_configs 
    fi
  }
  
- if [ -n $LOGIN_SHELL ]; then
 +function override_jb_variables {
 +  for VARIABLE in $(env)
 +  do
 +    NAME=${VARIABLE%%=*}
 +    if [[ $NAME = '_INTELLIJ_FORCE_SET_'* ]]
 +    then
 +      NEW_NAME=${NAME:20}
 +      if [ -n "$NEW_NAME" ]
 +      then
 +        VALUE=${VARIABLE#*=}
 +        export "$NEW_NAME"="$VALUE"
 +      fi
 +    fi
 +  done
 +}
 +
+ if [ -n "$LOGIN_SHELL" ]; then
    load_login_configs
    unset LOGIN_SHELL
  fi