Re: gpm buffer: CLI vs. X
Wayne Topa <linuxtwo@gmail.com>:
>
> I mentioned I was running Squeeze. I was not asking for help. I was
> relaying my attempts to get it to do what it says it can do. A CLI -> X
> clipboard APP that works is what I wanted. After reading all the docs
> supplied, as well as Googleing for other methods, I am left still wanting.
Forgive me if I've misunderstood your need, but I suggest this; CLI
perl script you can use in either X or CLI, wraps your paste in html
and datestamps it, concatenates to an existing web page:
------------------------
#!/usr/bin/perl
#
# ~/devl/perl/things.pl replaces ~/sh/things.sh; datestamps,
# separates, and pretty-prints entries.
#
# 13Apr2002 s. keeling 0001 replace things.sh
# 10Oct2004 s. keeling 0002 writes html
# 12Jun2005 s. keeling 0003 reformatting, < >
# 1Jul2005 s. keeling 0004 move to ~/dox
# ---------------------------------------------------------------
#
use strict;
use warnings;
my $outfile = qq($ENV{HOME}/dox/things_to_remember.html);
my $now;
chomp( $now = qx(date) );
open( THINGS, ">> $outfile" ) ||
die qq($0: could not open $outfile for append: $!);
print THINGS q( <li> ) . $now . q(<br>) . "\n";
print THINGS q( <pre>) . "\n";
while( <STDIN> ) {
s/\</</g;
s/\>/>/g;
print THINGS;
}
print THINGS q( </pre>) . "\n\n";
close( THINGS );
__END__
------------------------
--
Any technology distinguishable from magic is insufficiently advanced.
(*) http://blinkynet.net/comp/uip5.html Linux Counter #80292
- - http://www.faqs.org/rfcs/rfc1855.html Please, don't Cc: me.
Reply to: