findutils icon indicating copy to clipboard operation
findutils copied to clipboard

Implement `-fprint`

Open hanbings opened this issue 1 year ago • 7 comments

refer: https://www.gnu.org/software/findutils/manual/html_node/find_html/Print-File-Name.html

Action: -fprint file

True; print the entire file name into file file, followed by a newline. 
If file does not exist when find is run, it is created; if it does exist, it is truncated to 0 bytes. 
The named output file is always created, even if no output is sent to it. 
The file names /dev/stdout and /dev/stderr are handled specially; 
they refer to the standard output and standard error output, respectively.

If there is the faintest possibility that 
one of the files for which you are searching might contain a newline, 
you should use ‘-fprint0’ instead.

hanbings avatar May 11 '24 05:05 hanbings

this is fairly simple i think

keys-i avatar Jul 01 '24 15:07 keys-i

i could add a bit for file in in printer.rs

keys-i avatar Jul 01 '24 15:07 keys-i

i could add a bit for file in in printer.rs

sure, go ahead :)

hanbings avatar Jul 01 '24 17:07 hanbings

im made some addition to printer

keys-i avatar Jul 02 '24 08:07 keys-i

just need to add them to mod.rs

keys-i avatar Jul 02 '24 08:07 keys-i

i just need to see if the tests run or not

keys-i avatar Jul 02 '24 08:07 keys-i

okay so i need to make sure everything is gnu ok

keys-i avatar Jul 02 '24 08:07 keys-i

okay so i need to make sure everything is gnu ok

hi, please feel free to open a PR if you're ready, thanks. :)

hanbings avatar Jul 12 '24 16:07 hanbings