From: Masatake Y. <je...@gy...> - 2006-08-21 12:05:11
|
> 1. How do you think rename readarray to readfile? > > I think the shell script writer may be confused read -a and readarray. > readfile is more specific name. I did not rename it yet. I'm still looking for a good name. > > char *readarray_doc[] = { > "Copy the lines from the input file into an array variable.", > "Use the `-n' option to specify a count of the number of lines to copy.", > "If -n is missing all lines are copied.", > "Use the `-O' option to specify an index orgin to start the array.", > "If -O is missing the origin will be 0.", > "Use -t to chop trailing newlines (\\n) from lines.", > "To read from stdin use '-' as the filename.", > In stead of specifying filename, how do you think fd like > "read -u fd"? You can slow away `-'. > I did. The documentation is not updated but now readarray takes -u option for specify file descriptor. The file name is not acceptable. Use redirection instead. I'm changing the coding style(variable name conversion and indentation) to make it similar to that of bash. I'll use more bash functions in readarray.c. Then I'll convert readarray.c to readarray.patch:-P |