Gnus development mailing list
 help / color / mirror / Atom feed
* uptime in my sig
@ 1999-02-20  0:22 Bud Rogers
  1999-02-20  0:48 ` Hrvoje Niksic
  1999-02-20  0:48 ` Matt Pharr
  0 siblings, 2 replies; 6+ messages in thread
From: Bud Rogers @ 1999-02-20  0:22 UTC (permalink / raw)


I have thought for a while that it would be cool to append system uptime to 
my sig with gnus-posting styles, but I haven't figured out how to call
uptime.  It looks like there should be a way to do it with
view-process-mode.el, but so far nothing I've tried has worked.

Is anyone doing this?  Can I have a hint?

-- 

Bud Rogers <budr@sirinet.net>
http://www.sirinet.net/~budr/gnus.gif


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: uptime in my sig
  1999-02-20  0:22 uptime in my sig Bud Rogers
@ 1999-02-20  0:48 ` Hrvoje Niksic
  1999-02-22  1:07   ` Bud Rogers
  1999-02-20  0:48 ` Matt Pharr
  1 sibling, 1 reply; 6+ messages in thread
From: Hrvoje Niksic @ 1999-02-20  0:48 UTC (permalink / raw)


`(shell-command-to-string "uptime")' should do what you want.  Hooking 
this to `gnus-posting-styles' should be trivial.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: uptime in my sig
  1999-02-20  0:22 uptime in my sig Bud Rogers
  1999-02-20  0:48 ` Hrvoje Niksic
@ 1999-02-20  0:48 ` Matt Pharr
  1 sibling, 0 replies; 6+ messages in thread
From: Matt Pharr @ 1999-02-20  0:48 UTC (permalink / raw)



Bud Rogers <budr@sirinet.net> writes:
> I have thought for a while that it would be cool to append system uptime to 
> my sig with gnus-posting styles, but I haven't figured out how to call
> uptime.  It looks like there should be a way to do it with
> view-process-mode.el, but so far nothing I've tried has worked.

I used to have the following in my .gnus.el file to do that sort of thing.

(defun mmp:248-sig()
  (with-temp-buffer
    (insert-file "/u/mmp/.sig")
    (goto-char (point-max))
    (delete-backward-char 1)
    (insert-string "      ")
    (call-process "/u/mmp/bin/hfrac" nil t)
    (buffer-string)))

(setq gnus-posting-styles
      '(("^nnml:mail.cs248tas"
	 (signature mmp:248-sig))))

-matt
-- 
Matt Pharr                                   mmp@graphics.stanford.edu
<URL:http://graphics.stanford.edu/~mmp>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: uptime in my sig
  1999-02-20  0:48 ` Hrvoje Niksic
@ 1999-02-22  1:07   ` Bud Rogers
  1999-02-22  1:33     ` Jeremy D. Zawodny
  0 siblings, 1 reply; 6+ messages in thread
From: Bud Rogers @ 1999-02-22  1:07 UTC (permalink / raw)


Hrvoje Niksic <hniksic@srce.hr> writes:

> `(shell-command-to-string "uptime")' should do what you want.  Hooking 
> this to `gnus-posting-styles' should be trivial.
> 

Trivial for you, perhaps.  A marvelous learning exercise for me.  Thanks to 
all who gave me hints.

-- 

Bud Rogers <budr@sirinet.net> 	 http://www.sirinet.net/~budr/twocups.gif

  Linux twocups 2.0.33 #1 Sat Jul 25 15:53:48 CDT 1998 i586 unknown
  7:05pm  up 53 days,  8:37,  5 users,  load average: 0.39, 0.16, 0.16


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: uptime in my sig
  1999-02-22  1:07   ` Bud Rogers
@ 1999-02-22  1:33     ` Jeremy D. Zawodny
  1999-02-22  1:39       ` Bud Rogers
  0 siblings, 1 reply; 6+ messages in thread
From: Jeremy D. Zawodny @ 1999-02-22  1:33 UTC (permalink / raw)
  Cc: ding

Bud Rogers <budr@sirinet.net> writes:

> Hrvoje Niksic <hniksic@srce.hr> writes:
> 
> > `(shell-command-to-string "uptime")' should do what you want.  Hooking 
> > this to `gnus-posting-styles' should be trivial.
> > 
> 
> Trivial for you, perhaps.  A marvelous learning exercise for me.  Thanks to 
> all who gave me hints.

What was the final solution, anyway? (I'd like to do something similar
and don't feel like inventing another wheel today.)

I apologize if it was posted here already. If so, e-mail me privately
so as not to annoy anyone else.

Thanks,

Jeremy
-- 
Jeremy D. Zawodny                Web Geek, Perl Hacker, etc.
http://www.wcnet.org/~jzawodn/   jzawodn@wcnet.org

LOAD "LINUX",8,1



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: uptime in my sig
  1999-02-22  1:33     ` Jeremy D. Zawodny
@ 1999-02-22  1:39       ` Bud Rogers
  0 siblings, 0 replies; 6+ messages in thread
From: Bud Rogers @ 1999-02-22  1:39 UTC (permalink / raw)
  Cc: ding

jzawodn@wcnet.org (Jeremy D. Zawodny) writes:

> What was the final solution, anyway? (I'd like to do something similar
> and don't feel like inventing another wheel today.)
> 
> I apologize if it was posted here already. If so, e-mail me privately
> so as not to annoy anyone else.

Promise not to laugh?

(defun uptime-signature ()
  (insert "\n-- \n\n"
"Bud Rogers <budr@sirinet.net> \t http://www.sirinet.net/~budr/twocups.gif\n\n  "
(shell-command-to-string "uname -a")
(shell-command-to-string "uptime")))

(setq gnus-posting-styles
	[...]
	("ding"
	 (signature uptime-signature))




-- 

Bud Rogers <budr@sirinet.net> 	 http://www.sirinet.net/~budr/twocups.gif

  Linux twocups 2.0.33 #1 Sat Jul 25 15:53:48 CDT 1998 i586 unknown
  7:31pm  up 53 days,  9:03,  5 users,  load average: 0.39, 0.20, 0.19


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~1999-02-22  1:39 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-02-20  0:22 uptime in my sig Bud Rogers
1999-02-20  0:48 ` Hrvoje Niksic
1999-02-22  1:07   ` Bud Rogers
1999-02-22  1:33     ` Jeremy D. Zawodny
1999-02-22  1:39       ` Bud Rogers
1999-02-20  0:48 ` Matt Pharr

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).