[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
feature suggestion: configurable recipe echoing
From: |
Cook, Malcolm |
Subject: |
feature suggestion: configurable recipe echoing |
Date: |
Thu, 30 May 2024 21:41:07 +0000 |
Hi make-makers,
When using GNU Make as a workflow management tool, I use the feature [Choosing
the
Shell](https://www.gnu.org/software/make/manual/make.html#index-_002eSHELLFLAGS_002c-value-of)
and give SHELL (and .SHELLFLAGS) to [Target-specific Variable
Values](https://www.gnu.org/software/make/manual/make.html#Target_002dspecific).
Doing so allows me to write recipes in a mix of e.g. bash, perl, R, sql,
python, etc).
When doing so, I often wish I had the ability to configure Gnu Make's [Recipe
Echoing](https://www.gnu.org/software/make/manual/make.html#Echoing) to
identify the SHELL executing the recipe.
This would make the trace of recipe execution much more easily interpretable.
if I could, I would probably choose to prefix each line of echoed recipe with
the basename of the SHELL, followed by a colon and a space.
Perhaps we could introduce a new special variable, say .ECHO_FORMAT, which
might be expanded and used to printf the recipe about to be executed. It could
have its default set as follows:
.ECHO_FORMAT:=%s\n
... but could be used to my ends by setting it as:
.ECHO_FORMAT=$(basename ${SHELL}): %s\n
What do you think?
Malcolm Cook - Scientific Data and Applications Coordinator
Stowers Institute for Medical Research
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- feature suggestion: configurable recipe echoing,
Cook, Malcolm <=