fcreate

Package: WA2L/edrc 1.5.57
Section: Library Commands (3)
Updated: 31 January 2013
Index Return to Main Contents

 

NAME

fcreate - create a file if it does not exist

 

SYNOPSIS

edrc/lib/fcreate file [ text ]

 

AVAILABILITY

WA2L/edrc

 

DESCRIPTION

create a file if it does not exist. Optionally text can be written to the file created.

The intention of this command is to use it to create lock files within shell scripts. Or to atomically create a file if it does not exist.

The created file has the file permissions 0600.

 

OPTIONS

file
name of the file to be created.

text
text to be written to the file specified in the file option.

 

EXIT STATUS

0
specified file did not exist before and could be created.

1
specified file already exists.

2
error occurred during file creation.

 

FILES

-

 

EXAMPLES

-

 

SEE ALSO

edrcintro(1), open(3)

 

NOTES

-

 

BUGS

-

 

AUTHOR

fcreate was developed by Christian Walther. Send suggestions and bug reports to wa2l@users.sourceforge.net . 

 

COPYRIGHT

Copyright © 2013 Christian Walther

This is free software; see edrc/doc/COPYING for copying conditions. There is ABSOLUTELY NO WARRANTY; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


 

Index

NAME
SYNOPSIS
AVAILABILITY
DESCRIPTION
OPTIONS
EXIT STATUS
FILES
EXAMPLES
SEE ALSO
NOTES
BUGS
AUTHOR
COPYRIGHT

This document was created by man2html using the manual pages.
Time: 16:52:58 GMT, August 28, 2024