mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-03 22:35:43 +02:00
[290743] [dstore][shells] allow bash shells and custom shell invocation
This commit is contained in:
parent
2736805097
commit
5fb4c2106f
1 changed files with 30 additions and 21 deletions
|
@ -22,6 +22,7 @@
|
|||
* David McKnight (IBM) [153275] [dstore-shells] Ctrl+C does not break remote program
|
||||
* David McKnight (IBM) [284179] [dstore] commands have a hard coded line length limit of 100 characters
|
||||
* David McKnight (IBM) - [286671] Dstore shell service interprets < and > sequences
|
||||
* David McKnight (IBM) [290743] [dstore][shells] allow bash shells and custom shell invocation
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.rse.internal.dstore.universal.miners.command;
|
||||
|
@ -199,9 +200,6 @@ public class CommandMinerThread extends MinerThread
|
|||
else
|
||||
{
|
||||
isBash = true;
|
||||
// no bash!
|
||||
theShell = "sh"; //$NON-NLS-1$
|
||||
|
||||
}
|
||||
}
|
||||
else if (theShell.endsWith("sh") && isZ)//$NON-NLS-1$
|
||||
|
@ -220,6 +218,11 @@ public class CommandMinerThread extends MinerThread
|
|||
}
|
||||
}
|
||||
|
||||
// check for custom shell invocation
|
||||
String customShellInvocation = System.getProperty("DSTORE_SHELL_INVOCATION"); //$NON-NLS-1$
|
||||
if (customShellInvocation != null && customShellInvocation.length() > 0){
|
||||
theShell = customShellInvocation;
|
||||
}
|
||||
|
||||
if (theShell == null)
|
||||
{
|
||||
|
@ -320,6 +323,11 @@ public class CommandMinerThread extends MinerThread
|
|||
}
|
||||
else
|
||||
{
|
||||
if (customShellInvocation != null && customShellInvocation.length() > 0){
|
||||
// all handled in the custom shell invocation
|
||||
_theProcess = Runtime.getRuntime().exec(_invocation, env, theDirectory);
|
||||
}
|
||||
else {
|
||||
if (isBashonZ)
|
||||
{
|
||||
_theProcess = Runtime.getRuntime().exec(_invocation + " --login", env, theDirectory); //$NON-NLS-1$
|
||||
|
@ -341,6 +349,7 @@ public class CommandMinerThread extends MinerThread
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
_isTTY = false;
|
||||
|
|
Loading…
Add table
Reference in a new issue