Re: [RFC PATCH 0/4] Rewrite the check argument parsing
Zorro Lang <[email protected]>
| Newsgroups | org.kernel.vger.fstests |
|---|---|
| Message-ID | <an3ir0ZLiV260AFu@zlang-mailbox> |
Friendly ping ... Any review points about this patchset :) Thanks, Zorro On Tue, May 12, 2026 at 09:25:35PM +0800, Zorro Lang wrote: > The patchset here were motivated by a previous RFC discussion regarding: > https://lore.kernel.org/fstests/afzmt7SFA4jWhi6U@zlang-mailbox/T/#t > > This patchset refactors the argument parsing logic in the 'check' script. > The current positional parameter handling is becoming hard to maintain as > we add more options. > > I've replaced the manual parsing loop with *getopt* to provide a more > standard CLI experience, and ensured the functionality remains identical > to the previous implementation. > > Besides that, I also tried to make below 3 changes: > 1) Introduced --fs <fstyp> option, to replace all those filesystem-specific > options, e.g. -nfs, -overlay, -cifs and so on. > 2) Updated all long-format options to strictly use the double-dash (--) prefix. > 3) For backward compatibility, I tried to support legacy non-standard options > to ensure existing user workflows aren't broken. A deprecation warning is > now issued when these old options are used. > > I hope this patchset can facilitate future additions and adjustments to > arguments, making the code logic cleaner and more standardized. > > Any concerns or review points, please feel free to tell me :) > > Thanks, > Zorro > > Zorro Lang (4): > check: refactor argument parsing with getopt > check: update usage and README to reflect new argument parsing > check: consolidate argument handling into function > check: add deprecated options warning > > README | 10 +- > README.overlay | 18 +- > check | 435 ++++++++++++++++++++++++++++++++----------------- > common/config | 8 +- > common/rc | 2 +- > 5 files changed, 303 insertions(+), 170 deletions(-) > > -- > 2.54.0 > >