On Tue, 2018-06-12 at 07:52 +1000, Cameron Simpson wrote: > Personally I like "set -x". I've even got a tiny line script called "set-x" > which goes: > > #!/bin/sh > set -x > exec "$@" > > and many scripts which do variants on: > > trace= > [ -t 2 ] && trace=set-x # at least during development > ... > $trace important command here ... > ... Thank you for sharing your practice. It looks handy. > For proper utility scripts I tend to add a -x option to explicitly turn it on, > and -n to set it to "eecho", another tiny script which goes: > > #!/bin/sh > echo "$*" >&2 > > which gets you do-nothing tracing mode, 90% of what a -n needs. Could you please elaborate more on this? In `help set` I see that -n switches Bash into "dry run" mode. _______________________________________________ users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/users@xxxxxxxxxxxxxxxxxxxxxxx/message/C7H5IMRXYT25SCB5OBFDNBG4WH7HG2NM/