[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to have real newline in emdeded command lines?
From: |
Toomas Rosin |
Subject: |
Re: How to have real newline in emdeded command lines? |
Date: |
Sun, 20 Oct 2002 23:31:03 +0300 (EEST) |
Hello!
%% Jean-Cedric Chappelier <address@hidden> writes:
jc> What I want to do is to have a sed command emeded in the make
jc> directives, but this sed command has to have some newlines in there.
jc> So, is there a way to do this??
No.
Actually, there is, sort of.
Suppose you want to execute, from a Makefile, the following command:
echo 'a
b
c'
This can be done as follows:
( \
echo "echo 'a"; \
echo "b"; \
echo "c'" \
) | $(SHELL)
I don't know how portable this method is, but it works with bash-2.05.
I guess Jean-Cedric should do this:
@( \
echo 'psselect -q -p2 fichesresume.ps |\'; \
echo 'sed '\''/^TextDict begin$$/ a\'; \
echo 'SDict begin [ /CropBox [0 40 595 850] /PAGES pdfmark end\'; \
echo 'Someothestuff'\'' | ps2pdf - variables.pdf' \
) | $(SHELL)
Hope this helps,
Toomas.
P.S. Is there a standard way of replying to a message in this list
without having been sent it, i.e. only having read it in the archive?
I did "M-x rmail-input RET 2002-October.txt RET" and hit "r", but the
headers said something about imparsable addresses, so I had to mess
with headers manually, and me not a mail guru. Is there a better way?
T.