[File] Feature request / patch offer: What about a `--files-from0` option?

Christos Zoulas christos at zoulas.com
Fri Jun 7 22:28:52 UTC 2024


Sure, just send a patch. No copyright assignment needed...

christos

> On Jun 7, 2024, at 4:52 PM, Evan Driscoll <edriscoll at codesecure.com> wrote:
> 
> The `--0`​ option to `file` provides a nice way to get perfect parsing of results that include unfortunate file names.
> 
> However, there's not an analogue on the input side for providing filenames via a file, a la `--files-from`. Would it be possible to add an option, say `--files-from0`, that functions like `--files-from` except that the filenames are `\0` separated instead of newline-separated?
> 
> I've put my money where my mouth is a bit, and implemented this locally; with some light testing only, it seems to work. I *believe* I can offer this patch. Is it of interest? What are your contribution requirements in terms of copyright assignment and whatnot?
> 
> Thanks,
> Evan Driscoll
> ________________________________
> The information contained in this e-mail and any attachments from CodeSecure, Inc may contain confidential and/or proprietary information, and is intended only for the named recipient to whom it was originally addressed. If you are not the intended recipient, any disclosure, distribution, or copying of this e-mail or its attachments is strictly prohibited. If you have received this e-mail in error, please notify the sender immediately by return e-mail and permanently delete the e-mail and any attachments.
> -- 
> File mailing list
> File at astron.com
> https://mailman.astron.com/mailman/listinfo/file
> 
> -- 
> This message has been 'sanitized'.  This means that potentially
> dangerous content has been rewritten or removed.  The following
> log describes which actions were taken.
> 
> Sanitizer (start="1717799244"):
>  Split unusually long word(s) in header.
>  SanitizeFile (filename="unnamed.txt", mimetype="text/plain"):
>    Match (names="unnamed.txt", rule="9"):
>      Enforced policy: accept
> 
>  Total modifications so far: 1
> 
> 
> Anomy 0.0.0 : Sanitizer.pm
> $Id: Sanitizer.pm,v 1.94 2006/01/02 16:43:10 bre Exp $
> 



More information about the File mailing list