URL: <https://savannah.gnu.org/bugs/?59169>
Summary: Add a --debug=why category for the -d/--debug option Project: make Submitted by: boyski Submitted on: Wed 23 Sep 2020 02:22:35 AM UTC Severity: 3 - Normal Item Group: Enhancement Status: None Privacy: Public Assigned to: None Open/Closed: Open Discussion Lock: Any Component Version: 4.3 Operating System: None Fixed Release: None Triage Status: None _______________________________________________________ Details: This simple patch adds a --debug=why category to print the contents of $? for every recipe invoked. Extremely similar to --trace and in fact it piggybacks off the same code, the only difference being that it doesn't force the recipe to be printed like --trace does. Implemented because I find the ability to print $? quite useful but don't want to have to print the recipe too, and --trace per se cannot be changed compatibly. In my day job we have many recipes up to thousands of characters long so we generally silence them and print only "$(info Making $@)" by default. This makes --trace sub-optimal for us as it stands. In fact I wonder why --trace was implemented as a standalone flag instead of a --debug category? I'm sure there was a reason but I can't think of what it might be. If it was up to me I'd consider implementing both --debug=trace and --debug=why and documenting --trace as just an alias of --debug=trace. This needs a doc patch and so on but I'm ignoring those unless/until this idea is accepted. _______________________________________________________ File Attachments: ------------------------------------------------------- Date: Wed 23 Sep 2020 02:22:35 AM UTC Name: why.patch Size: 1KiB By: boyski <http://savannah.gnu.org/bugs/download.php?file_id=49845> _______________________________________________________ Reply to this item at: <https://savannah.gnu.org/bugs/?59169> _______________________________________________ Message sent via Savannah https://savannah.gnu.org/