🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nn
1 messages
1 total messages Started by Sudarshan S. Chawathe Mon, 01 Mar 1993 03:31
nn macro-mania; Help!
#3821
Author: Sudarshan S. Chawathe
Date: Mon, 01 Mar 1993 03:31
56 lines
2560 bytes
Aim: to be able to type a single key to see a postcript file included in
an article on screen using ghostview (and similarly for printing it).

( If someone already has some nifty macros for this, and could mail them
to me, I'd be most greatful, though at some point I would also like to
know what's happening with my macros...)

I have the foll macro defined in my init file:

# Print a Postcript file directly (stripping leading junk)
map show T (
	:set printer pstailview
	:print input
# The foll doesn't work!
#	:set printer "enscript -Ppalm2 -hG"
)

Problem 1:
If I uncomment the second :set command, nn complains with "Error in
macro 106"  I can't figure why.

Problem 2:
pstailview is a simple shell script (see below) that strips leading
junk from a postcript file present in its stdin and forward the result
to ghostview for displaying.   That works fine BUT if I try running
ghostview in the background, nn complains saying "command didn't read
complete article" and ghostview doesn't display anything either.

Problem 3:
If I replace pstailview with pstailpr, which is the same shell script as
before with lpr instead of ghostview at the end of the pipe, nn
complains with "command didn't read...", "exit status XXX" and nothing
gets printed either.

Here are the files in my bin that I'm using:

pstailview:
#!/bin/sh
/u/chaw/bin/getpstail | ghostview - 
# doesn't work if I put an & here------^

pstailpr:
#!/bin/sh
/u/chaw/bin/getpstail | lpr -Ppalm2 -h
# doesn't work at all

getpstail:
sed -e '/^%!/,$!d'


Help!  Thanks,

-Chaw

_________________________________________________________________________
Chaw@cs.Stanford.edu                                         tat tvam asi
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads