Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Fri 18 Apr 2014, 02:01
All times are UTC - 4
 Forum index » House Training » Users ( For the regulars )
How to pipe freshclam into urxvt via script?
Moderators: Flash, Ian, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [4 Posts]  
Author Message
Semme

Joined: 07 Aug 2011
Posts: 3268
Location: World_Hub

PostPosted: Sun 06 Jan 2013, 08:17    Post subject:  How to pipe freshclam into urxvt via script?  

As the title suggests I want the script to first open urxvt, call freshclam, execute, then stay open till completion. As I'm not sure what I'm hoping for will even work, the library bit may be excluded for the time being.
Code:
#!/bin/bash
export LD_LIBRARY_PATH=$HOME/glibc-2.15:$LD_LIBRARY_PATH
exec ???

Realize this needn't be limited to freshclam. An example using wget would be equally as valid.

Thanks for any help..
Back to top
View user's profile Send private message 
musher0


Joined: 04 Jan 2009
Posts: 3789
Location: Gatineau (Qc), Canada

PostPosted: Sun 06 Jan 2013, 14:00    Post subject:  

Greetings, Semme.

An urxvt script that works for any CLI is this:

Code:
#!bin/sh
# freshclam.sh
####
# export LD_LIBRARY_PATH=$HOME/glibc-2.15:$LD_LIBRARY_PATH
# Remove the number sign in front of the above line if need be.

urxvt -e freshclam


The "-e" tells urxvt to execute freshclam.
To keep urxvt opened until the CLI program has ended, the solution is simple : DO NOT add an ampersand ("&") at the end of the command line. (There are a few exceptions, but generally that works.)

The above script should open freshclam with its default parameters in the urxvt default window.

Enjoy!

musher0

_________________
"Logical entities must not be multiplied needlessly." / "Il ne faut pas multiplier les êtres logiques inutilement." (Ockham)
Back to top
View user's profile Send private message Visit poster's website 
Semme

Joined: 07 Aug 2011
Posts: 3268
Location: World_Hub

PostPosted: Sun 06 Jan 2013, 14:26    Post subject:  

Greetings Musher.

I see (and simpler than I thought). What I wasn't trying was an app that had some business remaining open, say..
Code:
xterm -e wget http://ftp.nluug.nl/ftp/pub/os/Linux/distr/quirky/wary-5.3/wary-5.3.iso

Fact is I haven't swung over to Wary to proof the actual program.. a task I'll be addressing shortly..

Hopefully- I'll get the latest version running without the need for a rebuild.

Thanks Wink again..
Back to top
View user's profile Send private message 
musher0


Joined: 04 Jan 2009
Posts: 3789
Location: Gatineau (Qc), Canada

PostPosted: Sun 06 Jan 2013, 14:41    Post subject:  

My pleasure! Smile
_________________
"Logical entities must not be multiplied needlessly." / "Il ne faut pas multiplier les êtres logiques inutilement." (Ockham)
Back to top
View user's profile Send private message Visit poster's website 
Display posts from previous:   Sort by:   
Page 1 of 1 [4 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » House Training » Users ( For the regulars )
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0432s ][ Queries: 12 (0.0082s) ][ GZIP on ]