2 ms·
aside: Please no `backticks` $(cat tmp.ci.pid) is standard and never worse than backticks. Indifferent in your example but frequently it's vastly safer. backtic
by harry8 12y ago
aside: Please no `backticks` $(cat tmp.ci.pid) is standard and never worse than backticks. Indifferent in your example but frequently it's vastly safer. backticks need to be deprecated.
- shabble 12y agowhilst this is good advice for shell scripting, are you sure it applies as worded to the snippet you're replying to, given how Make uses $() itself for variable referencing?[1] $$() might work, but untested. [1] https://www.gnu.org/software/make/manual/html_node/Reference.html#Reference https://www.gnu.org/software/make/manual/html_node/Reference...
- harry8 12y agoyes, absolutely $$() works in a makefile. Backticks just need to die.
- untothebreach 12y agoyea, at least with GNU Make it is probably best to use $(shell cat tmp.ci.pid)
- oso2k 12y agoHaha. Good catch, I actually use $(shell cat tmp.ci.pid) to capture the PID in a var $(TMPCI) if you look at the actual Makefile I linked.