From 8894e69670c24a6d6dee1bc31706a11c7dc82f38 Mon Sep 17 00:00:00 2001 From: Emil Valeev Date: Wed, 2 Oct 2024 01:08:33 +0500 Subject: [PATCH] fix(cli:run): add missing binding for stdin when we execute os cmd to run executable file on FS --- .gitignore | 1 + internal/cli/run.go | 1 + 2 files changed, 2 insertions(+) diff --git a/.gitignore b/.gitignore index 2ff726d4..fcd5f6d8 100644 --- a/.gitignore +++ b/.gitignore @@ -22,6 +22,7 @@ cmd/tmp /neva-windows-arm64.exe dist trace.log +output node_modules __debug* diff --git a/internal/cli/run.go b/internal/cli/run.go index 3e39dce1..702fba7d 100644 --- a/internal/cli/run.go +++ b/internal/cli/run.go @@ -44,6 +44,7 @@ func newRunCmd(workdir string, nativec compiler.Compiler) *cli.Command { } cmd := exec.Command(filepath.Join(workdir, "output")) + cmd.Stdin = os.Stdin cmd.Stdout = os.Stdout cmd.Stderr = os.Stderr if err := cmd.Run(); err != nil {