digitalmars.D - creating a temporary fifo (tmpfile but for fifo)
- Timothee Cour via Digitalmars-d (5/5) Feb 12 2017 * std.stdio.tempfile creates an (unnamed) File. How do I create a tempor...
- Paul Backus (7/14) Feb 13 2017 Yes, using mkdtemp. [2]
- Andrei Alexandrescu (2/15) Feb 13 2017 They're declared in core.sys,posix.stdlib. -- Andrei
- Paul Backus (4/13) Feb 16 2017 Thanks for the tip. Is this module documented anywhere? I can't
- John Colvin (4/18) Feb 16 2017 For some reason it doesn't seem to be on the website, but the
- Timothee Cour via Digitalmars-d (3/6) Feb 16 2017 I meant adding a D api to add a temp file rooted under a specified
- Anonymouse (2/5) Feb 17 2017 Use the Source, Luke!
* std.stdio.tempfile creates an (unnamed) File. How do I create a temporary fifo instead? my workaround is to use tempnam but docs says it's not recommended ( http://man7.org/linux/man-pages/man3/tempnam.3.html) * could we allow specifying a directory name for tmpfile?
Feb 12 2017
On Sunday, 12 February 2017 at 11:47:26 UTC, Timothee Cour wrote:* std.stdio.tempfile creates an (unnamed) File. How do I create a temporary fifo instead? my workaround is to use tempnam but docs says it's not recommended ( http://man7.org/linux/man-pages/man3/tempnam.3.html)I believe the recommended function for this is mkstemp. [1]* could we allow specifying a directory name for tmpfile?Yes, using mkdtemp. [2] Note that these functions are part of POSIX but not C99, and are not included in D's core.stdc module. [1] http://man7.org/linux/man-pages/man3/mkstemp.3.html [2] http://man7.org/linux/man-pages/man3/mkdtemp.3.html
Feb 13 2017
On 2/13/17 12:12 PM, Paul Backus wrote:On Sunday, 12 February 2017 at 11:47:26 UTC, Timothee Cour wrote:They're declared in core.sys,posix.stdlib. -- Andrei* std.stdio.tempfile creates an (unnamed) File. How do I create a temporary fifo instead? my workaround is to use tempnam but docs says it's not recommended ( http://man7.org/linux/man-pages/man3/tempnam.3.html)I believe the recommended function for this is mkstemp. [1]* could we allow specifying a directory name for tmpfile?Yes, using mkdtemp. [2] Note that these functions are part of POSIX but not C99, and are not included in D's core.stdc module. [1] http://man7.org/linux/man-pages/man3/mkstemp.3.html [2] http://man7.org/linux/man-pages/man3/mkdtemp.3.html
Feb 13 2017
On Tuesday, 14 February 2017 at 03:15:53 UTC, Andrei Alexandrescu wrote:On 2/13/17 12:12 PM, Paul Backus wrote:Thanks for the tip. Is this module documented anywhere? I can't find it in the dlang.org docs.[...] Note that these functions are part of POSIX but not C99, and are not included in D's core.stdc module. [1] http://man7.org/linux/man-pages/man3/mkstemp.3.html [2] http://man7.org/linux/man-pages/man3/mkdtemp.3.htmlThey're declared in core.sys,posix.stdlib. -- Andrei
Feb 16 2017
On Thursday, 16 February 2017 at 17:27:51 UTC, Paul Backus wrote:On Tuesday, 14 February 2017 at 03:15:53 UTC, Andrei Alexandrescu wrote:For some reason it doesn't seem to be on the website, but the source is here to read: https://github.com/dlang/druntime/blob/master/src/core/sys/posix/stdlib.dOn 2/13/17 12:12 PM, Paul Backus wrote:Thanks for the tip. Is this module documented anywhere? I can't find it in the dlang.org docs.[...] Note that these functions are part of POSIX but not C99, and are not included in D's core.stdc module. [1] http://man7.org/linux/man-pages/man3/mkstemp.3.html [2] http://man7.org/linux/man-pages/man3/mkdtemp.3.htmlThey're declared in core.sys,posix.stdlib. -- Andrei
Feb 16 2017
I believe the recommended function for this is mkstemp. [1]Mkstemp creates a regular file, not a fifo* could we allow specifying a directory name for tmpfile?Yes, using mkdtemp. [2]I meant adding a D api to add a temp file rooted under a specified directory; the C api's allow that but not tempfile
Feb 16 2017
On Thursday, 16 February 2017 at 17:49:07 UTC, John Colvin wrote:For some reason it doesn't seem to be on the website, but the source is here to read: https://github.com/dlang/druntime/blob/master/src/core/sys/posix/stdlib.dUse the Source, Luke!
Feb 17 2017