From: Geoff Collyer <geoff@collyer.net>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] sam -d reading from stdin?
Date: Sat, 31 Jan 2004 16:30:48 -0800 [thread overview]
Message-ID: <0288a322700f9cc8be0ca4f087ed3d9f@collyer.net> (raw)
In-Reply-To: <9c6fb52b5257fc8333b5722123939d01@collyer.net>
[-- Attachment #1: Type: text/plain, Size: 324 bytes --]
Whoops, that script won't make much sense, since the carriage returns
(ascii or utf 015) got turned into newlines (ascii or utf 012). If
you replace each ~ with a carriage return, the script should look like
this:
tcs -f msdos <$file |[3=1] sam -d /fd/3 <<'!' >[2]/dev/null
,x/~+$/ d
,x/~+/ x/~/ c/\n/
w /fd/1
!
[-- Attachment #2: Type: message/rfc822, Size: 1889 bytes --]
From: Geoff Collyer <geoff@collyer.net>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] sam -d reading from stdin?
Date: Sat, 31 Jan 2004 16:18:21 -0800
Message-ID: <9c6fb52b5257fc8333b5722123939d01@collyer.net>
This is how I use sam -d in a pipeline, taken from an existing shell script:
tcs -f msdos <$file |[3=1] sam -d /fd/3 <<'!' >[2]/dev/null
,x/
+$/ d
,x/
+/ x/
/ c/\n/
w /fd/1
!
next prev parent reply other threads:[~2004-02-01 0:30 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-01-31 12:40 Matthias Teege
2004-01-31 13:07 ` David Presotto
2004-02-01 0:18 ` Geoff Collyer
2004-02-01 0:30 ` Geoff Collyer [this message]
2004-02-01 3:31 ` boyd, rounin
2004-02-01 13:51 ` Matthias Teege
2004-02-01 14:03 ` boyd, rounin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=0288a322700f9cc8be0ca4f087ed3d9f@collyer.net \
--to=geoff@collyer.net \
--cc=9fans@cse.psu.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).