Home Download Buy Blog Forum Support

exec question

exec question

Postby gordon on Thu Jun 24, 2010 2:36 pm

I set up an exec action that would run the ruby gist command a the command line:

Code: Select all
<binding key="f12" command="exec  '' 'gist.bat --simple &quot;$File&quot;" />

When I ran it, it would hang. I found it was hanging on this line in the gist code:

Code: Select all
if $stdin.tty?
  # Run without stdin.
  # Read from standard input.
  input = $stdin.read

In other words, $stdin.tty is returning false, and it's waiting to read from $stdin. I just want it to read from the file I provide in the exec line, so this doesn't work for me. I ended up commenting the if/else code out, so it would run without stdin.

I'm not calling this a bug in Sublime. I just really don't understand what's causing this, or if there is a way to fix it without commenting out the code.

Posts: 10
Joined: Mon Mar 24, 2008 3:47 pm

Return to Technical Support

Who is online

Users browsing this forum: Yahoo [Bot] and 21 guests