commandline use more one command show error #11230

Closed
opened 2026-01-31 02:42:03 +00:00 by claunia · 2 comments
Owner

Originally created by @lmcmceo on GitHub (Oct 30, 2020).

if I input "echo '12345';ssh lotteryprod@192.168.1.1", it show 12345 and then require my password,
but I use the following settings
{
"closeOnExit": true,
"commandline": "echo '12345';ssh lotteryprod@192.168.1.1",
"guid": "{592D0432-1020-4DF6-83D4-928A7BE1D31B}",
"name": "Test"
}

it shows
[start“echo '12345'” error 0x80070002]
is this a bug ?

Originally created by @lmcmceo on GitHub (Oct 30, 2020). if I input "echo '12345';ssh lotteryprod@192.168.1.1", it show 12345 and then require my password, but I use the following settings { "closeOnExit": true, "commandline": "echo '12345';ssh lotteryprod@192.168.1.1", "guid": "{592D0432-1020-4DF6-83D4-928A7BE1D31B}", "name": "Test" } it shows [start“echo '12345'” error 0x80070002] is this a bug ?
claunia added the Needs-Tag-FixResolution-Answered labels 2026-01-31 02:42:04 +00:00
Author
Owner

@skyline75489 commented on GitHub (Oct 30, 2020):

No I don't think this is a bug. The commandline is not the same as whatever you type inside a shell (in this case powershell). The commandline needs to be a program that can be found and spawned by the terminal. In this case you need to use something like this:

{
    "commandline": "powershell -Command echo '12345';ssh lotteryprod@47.242.87.20",
}
@skyline75489 commented on GitHub (Oct 30, 2020): No I don't think this is a bug. The `commandline` is not the same as whatever you type inside a *shell* (in this case powershell). The `commandline` needs to be a *program* that can be found and spawned by the terminal. In this case you need to use something like this: ```json { "commandline": "powershell -Command echo '12345';ssh lotteryprod@47.242.87.20", } ```
Author
Owner

@skyline75489 commented on GitHub (Oct 30, 2020):

See here for the difference between a shell and a terminal. Or search online for more detailed explanation. If you're really interested , the keywords would be "shell", "terminal", "CLI" and "tty".

And BTW you should not leak sensitive information like IP addresses, just for your own sake.

@skyline75489 commented on GitHub (Oct 30, 2020): See [here](https://github.com/microsoft/terminal/blob/main/doc/Niksa.md#whats-the-difference-between-a-shell-and-a-terminal) for the difference between a shell and a terminal. Or search online for more detailed explanation. If you're really interested , the keywords would be "shell", "terminal", "CLI" and "tty". And BTW you should not leak sensitive information like IP addresses, just for your own sake.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#11230