#526701 licensecheck: options: recursive scan should check all files (--check=".*" by default) #526701
- Package:
- licensecheck
- Source:
- licensecheck
- Submitter:
- Frédéric Brière
- Date:
- 2023-05-14 11:57:07 UTC
- Severity:
- normal
licensecheck currently applies $opt_check_regex to all command line arguments if there are more than one. This is very counter-intuitive: $ touch foo $ licensecheck * foo: *No copyright* UNKNOWN $ touch bar licensecheck * $ I'd argue that $opt_check_regex should never be applied to the command line; I'm not aware of any tools that silently ignore such arguments. (The point could also be made against $opt_ignore_regex.) --- /etc/devscripts.conf ------ ~/.devscripts --- DEBCHANGE_RELEASE_HEURISTIC=changelog USCAN_SYMLINK=rename DEBCOMMIT_STRIP_MESSAGE=yes
was that it allowed to say "what is the license of this file", even if that single file did not match the default set of files which are checked. Admittedly, the same may be achieved using "licensecheck -c . $file". This might be losing something in translation. :-) Given that licensecheck is a command line tool, how can those options /not/ "be applied to the command line"? Regards, Adam
Makes sense. My beef is that it suddenly goes away when I ask "what is the license of these two files". I would draw a parallel with ls(1): if I type "ls" or "ls <dir>", I expect that some entries in <dir> will be ignored by default. However, if I explicitly ask "ls .bashrc", I now expect that file to be listed, with or without "-a". IOW, it's line 261 that I'm against, not line 256. :)
I understand what you mean, and can see the logic. However, the parallel doesn't quite map, as "licensecheck" on its own currently gives usage instructions, rather than being equivalent to "licensecheck .". My concern is whether people currently expect "licensecheck *" on a directory containing many files to actually inspect every single file or only those which match the default regex. If the expectation is the latter then I'm not sure where to go from there, given that the script can't tell the difference between you calling "licensecheck *" and "licensecheck filea fileb filec ... filezz". Regards, Adam
Good morning, Attached please find your PDF account statement and invoice as of 05/11/2023. Please notice you have a past due balance for invoice IN0099203. Please provide payment as soon as possible. Best Regards, Shawneen Chisholm Accounts Receivable Coordinator UNITED RENTALS, INC. Branch L02 BONNYVILLE 4920 56TH AVE BONNYVILLE AB T9N 2N8 CA 780-826-7610 CONFIDENTIALITY NOTICE: The contents of this email message and any attachments are intended solely for the addressee(s). This may contain confidential and/or privileged information and may be legally protected from disclosure. If you are not the intended recipient of this message, please alert the sender immediately by reply email and then delete this message and any attachments. Any disclosure, reproduction, distribution or other use of this message or any attachments by an individual or entity other than the intended recipient is prohibited