How do I write some (bash) shell script to convert all matching filenames in directory to command-line options?
问题 Apparently the answer to my question "Can I restrict nose coverage output to directory (rather than package)?" is no, but I can pass a --coverage-package=PACKAGE option to nose with the package name of each .py file in the directory. So for example, if the directory contains: foo.py bar.py baz.py ...then I would need to use the command: nosetests --with-coverage --coverage-package=foo --coverage-package=bar --coverage-package=baz So my question is, can someone write some shell script code