appulate / vscode-file-watcher

Extension for Visual Studio Code allows configuring commands that get run whenever a file is saved or folder is changed in vscode.
MIT License
39 stars 22 forks source link

[error] the input device is not a TTY. If you are using mintty, try prefixing the command with 'winpty' #12

Closed ThePlenkov closed 4 years ago

ThePlenkov commented 4 years ago

Hi!

I have a following settings file:

{
  "filewatcher.commands": [
    {
      "match": "\\.puml",
      "isAsync": true,
      "cmd": "docker run --rm -it  --mount type=bind,source=${workspaceRoot},target=/app theplenkov/plantuml-docker",
      "event": "onFileChange"
    }
  ]
}

when i try to create any *.puml file i have output like this:

[Event handled] ...
[onFileChange] for pattern "\.puml" started
[cmd] docker run --rm -it  --mount type=bind,source=c:\Users\pplenkov\Documents\git_projects\comments-service,target=/app theplenkov/plantuml-docker
[error] the input device is not a TTY.  If you are using mintty, try prefixing the command with 'winpty'

Do you have any ideas why?

The command is working properly if input directly into CLI

VovanNet commented 4 years ago

Try to quote target param like target='/app theplenkov/plantuml-docker'. Space is delimeter for windows cmd line

ThePlenkov commented 4 years ago

but space is in the correct position. theplenkov/plantuml-docker - is the name of the image, not the target.

ThePlenkov commented 4 years ago

it was just -t issue with docker command. I kept just -i. So all good!