xv_get_sel alike tools for Linux 

Newsgroups: comp.os.linux.misc
> > >I'm looking for xv_get_sel alike tools for Linux.
> > >
> > Would this be something like xclipboard maybe (standard with X)?
> > Then there's xfilesel which I guess copies a selection to a file
> > and back to an X selection.
>
>Thanks, what I am really looking for is *command line* tools so that
>I can easily use them within my script. Sorry I didn't make myself
>clear at the first place.

The closest thing I found so far is xsel. Apparently it can be used in scripts and whatnot. I only gave it a quick look-at just now. Even though it's command line some little window pops up and then exits. Not sure what that's for yet. Still not the same as xv_get_sel.

http://www.niksula.cs.hut.fi/~vherva/xsel/

It's a single xsel.c file.

cmd:xsel 

Usage 

netscape -remote "openURL(`xsel -p`, new-window)" &

compile: 

Linux:

gcc xsel.c -O6 -o xsel -lX11 -lXt -lXaw -L /usr/X11R6/lib/

Solaris:

gcc xsel.c -O6 -o xsel -lX11 -lXt -lXaw -lXmu -L /usr/X11R6/lib/

Install 

Linux:

mv ~/dl/mustH_b/xwin/xsel /opt/bin

Solaris:

mv xsel ~/local/bin/