[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Monotone-devel] [PATCH] New lua command execute_redirout which exec
From: |
Timothy Brownawell |
Subject: |
Re: [Monotone-devel] [PATCH] New lua command execute_redirout which executes an os command and captures standard output |
Date: |
Mon, 14 Aug 2006 14:56:31 -0500 |
On Mon, 2006-08-14 at 15:39 -0400, Daniel Dickinson wrote:
> Erm, but I think mkstemp returns a file handle and spawn_redirected
> takes a filename which it opens (and truncates) or creates, so you
> can't simply feed the output of lua's mkstemp() into spawn_redirected
> unless lua file handles are just filenames.
It returns both. But looking at it, you probably actually want
temp_file() since mkstemp() needs a filename template as an argument,
while temp_file knows how to make one.
local file, filename = temp_file() -- calls mkstemp($TMPDIR/mtn.XX)
file:close() -- because we don't need it
-- filename = $TMPDIR/mtn.XXXX
should work?
Tim
--
Free (experimental) public monotone hosting: http://mtn-host.prjek.net
- [Monotone-devel] [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Daniel Dickinson, 2006/08/14
- Re: [Monotone-devel] [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Timothy Brownawell, 2006/08/14
- Re: [Monotone-devel] [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Nathaniel Smith, 2006/08/14
- Re: [Monotone-devel] [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Daniel Dickinson, 2006/08/14
- Re: [Monotone-devel] [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Bruce Stephens, 2006/08/14
- [Monotone-devel] Re: [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Graydon Hoare, 2006/08/14
- Re: [Monotone-devel] Re: [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Timothy Brownawell, 2006/08/14
- [Monotone-devel] Re: [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Graydon Hoare, 2006/08/15
- Re: [Monotone-devel] Re: [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Bruce Stephens, 2006/08/15
- Re: [Monotone-devel] Re: [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Daniel Carosone, 2006/08/15
- [Monotone-devel] Re: [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Bruce Stephens, 2006/08/15
- Re: [Monotone-devel] Re: [PATCH] New lua command execute_redirout which executes an os command and captures standard output, Alex Queiroz, 2006/08/16