Skip to content

Commit

Permalink
Don't use bash and stty to spawn child process
Browse files Browse the repository at this point in the history
  • Loading branch information
tompng committed Sep 6, 2024
1 parent 415a438 commit f766616
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/yamatanooroti/vterm.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ def start_terminal(height, width, command, wait: 0.01, timeout: 2, startup_messa
@wait = wait
@result = nil

@pty_output, @pty_input, @pid = PTY.spawn('bash', '-c', %[stty rows #{height.to_s} cols #{width.to_s}; "$@"], '--', *command)
@pty_output, @pty_input, @pid = PTY.spawn(*command)
@pty_output.winsize = [height, width]

@vterm = VTerm.new(height, width)
@vterm.set_utf8(true)
Expand Down

0 comments on commit f766616

Please sign in to comment.