🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.epoch.misc
Article #1385

Re: Emacsclient getting new screen?

#1385
From: patrick m. ryan
Date: Fri, 29 May 1992 12:01
87 lines
2901 bytes
In article <1992May28.181519.6650@nas.nasa.gov>, browning@willard.nas.nasa.gov (David S. Browning) writes:
> Epoch 4.0p1 on SGI Iris 4D running Irix 4.0.1.
> 
> I use emacsclient from within xrn to edit outgoing posts and mail.  I
> would like Epoch to open a new screen in which to edit the temporary
> file supplied by xrn.  Is there a way to modify emacsclient to do this
> under Epoch?

	use Andy Norman's gnuclient package.  its much better than
emacsclient.  this is from the documentation:

-----

DESCRIPTION
     gnuclient allows the user to request  a  running  GNU  Emacs
     process to edit the named files or directories.

     gnudoit allows the user to request a running GNU Emacs  pro-
     cess  to  evaluate  the  given arguments inside a progn LISP
     form.

     gnuserv is the server program that is  set  running  by  GNU
     Emacs  to  handle  all incoming and outgoing requests. It is
     not usually invoked directly, but is started from GNU  Emacs
     by the LISP form (server-start).

-----

here is a script that i call from xrn:

#!/bin/sh
#
#   a little script to edit a file in an existing emacs window.
#

tmp=/tmp/.junk.$$
###pwd=`/bin/pwd`

whosed () { sed 's/^/'$1' - /' ; }

# raise window
gnudoit -q '(epoch::mapraised-screen)' | whosed gnudoit  > $tmp

# bail out if there was a problem raising the window
if [ $? -ne 0 ]
then
	cat $tmp
	exit 1
fi

# edit the file(s)
for file in $*
do
	# edit
	gnuclient $file  | whosed gnuclient >> $tmp
###	gnudoit "(cd \"$pwd\")" | whosed gnudoit >> $tmp

	# get rid of the buffer
	buf=`basename $file`
	gnudoit -q "(kill-buffer \"$buf\")" | whosed gnudoit >> $tmp

done

gnudoit '(epoch::iconify-screen)' | whosed gnudoit >> $tmp

if [ $? -ne 0 ]
then
	cat $tmp
	exit 1
fi

rm -f $tmp

exit 0


------

	you can get this from your friendly neighborhood elisp
archive site.

pat

--
                                                             patrick m. ryan
            nasa / goddard space flight center / oceans and ice branch / stx
                     pat@jaameri.gsfc.nasa.gov / zmpmr@charney.gsfc.nasa.gov
Technical Details
Message-ID: <1992May29.120152.11464@nsisrv.gsfc.nasa.gov>
Path: arc1-ca.pugleaf.net!sparky!uunet!dtix!darwin.sura.net!ukma!nsisrv!jaameri!pat
References: <1992May28.181519.6650@nas.nasa.gov>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: fc7ee,bdba287d3204d3fc
X-Google-Attributes: gidfc7ee,public
X-Google-ArrivalTime: 1992-05-29 03:35:30 PST
Path: arc1-ca.pugleaf.net!sparky!uunet!dtix!darwin.sura.net!ukma!nsisrv!jaameri!pat
From: pat@jaameri.gsfc.nasa.gov (patrick m. ryan)
Newsgroups: gnu.epoch.misc
Subject: Re: Emacsclient getting new screen?
Message-ID: <1992May29.120152.11464@nsisrv.gsfc.nasa.gov>
Date: 29 May 92 12:01:52 GMT
References: <1992May28.181519.6650@nas.nasa.gov>
Sender: usenet@nsisrv.gsfc.nasa.gov (Usenet)
Reply-To: pat@jaameri.gsfc.nasa.gov (patrick m. ryan)
Distribution: na
Organization: Oceans & Ice Branch, NASA/GSFC/STX
Lines: 87
Nntp-Posting-Host: jaameri.gsfc.nasa.gov