On Mon, Aug 28, 2023 at 08:14:31AM -0700, Bart Van Assche wrote: > On 8/27/23 21:13, Shinichiro Kawasaki wrote: > > For me, your original suggestion to add "ignored_agument" looks better > > than "$@". (or in short, "noarg" or something) > > It is not clear to me what the intention is of the _nvmet_target_setup > calls without arguments. Create a target. That's it. It is really not that complicated. > Is the intention to pass all arguments that have > been passed to the caller or is the intention not to pass any > arguments? If there are no arguments, the indent is not to pass any arguments. > In the latter case I think it would be wrong to suppress SC2119 because > there really is a problem in this case. IMO, SC2119 is not helping at all. What does it prevent? It doesn't even understand how many arguments are supposed to be passed into a function. The few error cases it catches are very limitted. > How about passing -- as argument > if the intention is not to pass any arguments? It is a well established > convention for shell commands and shell functions to ignore the double > hyphen if it is encountered in the argument list. I am against adding code just to make ShellCheck happy. If there is another way achieve this I am all ear.