Try these two commands:

$ echo "Date: `date #comment`"
Date: Thu Jul 27 10:28:13 CEST 2023

$ echo "Date: $(date #comment)"
)"
Date: Thu Jul 27 10:27:58 CEST 2023


As you see, #comment is handled differently in `` and $().
I think the handling in `` makes more sense.


Reply via email to