Skip to content

Cannot run interactive tasks with apps like sudo #5

@mrkeuz

Description

@mrkeuz

Hi, thanks for great plugin! 🚀

Found issue. Inside IDE, you cannot run interactive tasks like sudo.
From plain console all works fine as expected.

Steps for reproduce:

  • Create run config for task sudo_test
  • Run config

Task target example:

version: 3
tasks:
  sudo_test:
    cmds:
      - sudo echo hello
    interactive: true

# Output after run:

# task --taskfile /home/.../Taskfile.yaml sudo_test
# task: [sudo_test] sudo echo hello
# sudo: a terminal is required to read the password; either use the -S option to read from standard input or  configure an askpass helper
# task: Failed to run task "sudo_test": exit status 1
# 
# Process finished with exit code 1

Other run configurations has options "Emulate terminal..." (python run) or "Execute in terminal..." (shell).
Likely Task plugin should have similar option for fix (not sure, I'm not a plugin developer).

image

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions