coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Split pathchk's -p into multiple flags?


From: Pádraig Brady
Subject: Re: Split pathchk's -p into multiple flags?
Date: Mon, 9 Jan 2023 13:55:27 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Thunderbird/109.0

On 08/01/2023 23:07, Victor Engmark via GNU coreutils General Discussion wrote:
Hi,

I'd like to enforce the POSIX portable file name character set in my
projects, which `pathchk -p` does, but I don't want to enforce the
POSIX maximum path component length of 14 characters, which it also
does. Would it be useful to introduce separate flags for the three
rules enforced by `-p`? One to enforce non-empty file names, one to
enforce the POSIX portable file name character set, and one to enforce
the POSIX maximum path component length.

This is a fair suggestion as the path component length is
generally too restrictive these days.
For example the coreutils sources don't comply with
the POSIX 14 char limit.

I suppose we could have --posix=all,naming,length
with -p equivalent to --posix=all

For my reference I wrote a similar util a long time ago
to split the checks over 4 levels of sensitivity,
when length and character patterns varying for each level:
https://github.com/pixelb/fslint/blob/master/fslint/findnl

cheers,
Pádraig



reply via email to

[Prev in Thread] Current Thread [Next in Thread]