Dear List
I am trying to check some modules are installed or not in the system and if
modules are installed then trying to check their version number is according
to our requirement or not.
use strict;
use warning;
my @mod_info=("DBD::Oracle","abc","DBI","Parallel::ForkManager",);
my $module;
my $
Term::ReadLine::GNU just stopped working:
$ perl -e 'use Term::ReadLine; $t=Term::ReadLine->new("test");'
Segmentation fault
OS is linux, kernel 2.6.25. Perl version is 5.8.8 (on a Pentium 4).
Term::ReadLine::GNU is version 1.17 (I also tried 1.16, no difference).
I had to reinst
I have several text files of prose that I need to do context diffs on.
However, these files have been through various editors and the line
sizes have been changed multiple times, so a line based tool will not
work. I really need a word based diff that can ignore white space
changes and show just th
Hi all
I don't want print the line numbers
For the following
1) Starting with .
2) Labels label: not for 1:
Example
Ghjgg
Hjh
..
Abcb:
ggghj
1:
G
Output should be
1 Ghjgg
2 Hjh
.
3 hhjkhjkh
Abcb:
4 ggghj
5 1:
6 g
Thanks and regards
Gowri
DISCLAIMER:
---
Mr. Shawn H. Corey wrote:
On Tue, 2008-11-04 at 16:30 +0100, Rob Coops wrote:
What you want to be doing is this: $temp =~ s/\s+/ /g;
Actually to substitute multiple spaces with just one:
$temp =~ s/ +/ /g;
Or as some prefer:
$temp =~ s{ [ ]+ }{ }gx;
Not if speed is an issue:
$ perl -le'
Sharan Basappa wrote:
Hi,
Hello,
I have string that has one or more spaces. I would like to replace
them with a single space.
$ perl -le'
my $temp = "0 1 2 34";
print $temp;
$temp =~ tr/ //s;
print $temp;
'
0 1 2 34
0 1 2 3 4
The simple code below replaces the spaces fine,
On Tue, 2008-11-04 at 16:37 +0100, Rob Coops wrote:
> On Tue, Nov 4, 2008 at 4:35 PM, Sharan Basappa <[EMAIL PROTECTED]>wrote:
> > Thanks. BTW, a variable ($x = " ") instead of actual space would do, right?
> >
>
> Yeah that should work just fine.
It is better to call it $SPACE:
my $SPACE = " ";
On Tue, 2008-11-04 at 16:30 +0100, Rob Coops wrote:
> What you want to be doing is this: $temp =~ s/\s+/ /g;
Actually to substitute multiple spaces with just one:
$temp =~ s/ +/ /g;
Or as some prefer:
$temp =~ s{ [ ]+ }{ }gx;
Or even:
$temp =~ s/\x20+/\x20/g;
The reason for not using the fi
On Tue, Nov 4, 2008 at 4:35 PM, Sharan Basappa <[EMAIL PROTECTED]>wrote:
> > You are completely right. :-)
> >
> > What you want to be doing is this: $temp =~ s/\s+/ /g;
> > The reason for that is simple, \s is used to match a space or multiple
> > spaces, it is not used to print a space that is a
> You are completely right. :-)
>
> What you want to be doing is this: $temp =~ s/\s+/ /g;
> The reason for that is simple, \s is used to match a space or multiple
> spaces, it is not used to print a space that is actually done by the ' '
> (space). It might seem a little strange at first but just
Hi,
I am having problems with cygwin/dbd-oracle
1. I have installed cygwin
2. I have installed DBI-1.607
3. I am trying to compile DBD-Oracle-1.22
This is the step creating the issue -->
$ perl Makefile.PL
Oracle version 9.2.0.1 (9.2)
OCI directory not found, please install OCI in C:/xxx/Oracle92
On Tue, Nov 4, 2008 at 4:21 PM, Sharan Basappa <[EMAIL PROTECTED]>wrote:
> Hi,
>
> I have string that has one or more spaces. I would like to replace
> them with a single space.
> The simple code below replaces the spaces fine, but does not
> substitute with a space.
>
> $temp = "0 1 2 34";
Hi,
I have string that has one or more spaces. I would like to replace
them with a single space.
The simple code below replaces the spaces fine, but does not
substitute with a space.
$temp = "0 1 2 34"; <-> version 1
$temp =~ s/\s+/\s/g;
$temp = "0 1 2 34"; <-> version 2
$temp =~ s
On Tue Nov 04 2008 @ 4:11, Rob Dixon wrote:
> > Rob Dixon wrote:
> If I had things my way there would never be any use of Perl as a command-line
> tool.
Isn't this throwing out the baby with the bathwater? Here's a random, real,
recent example of why I'm not giving up Perl on the command line. I
> My final comment is that $temp is an awful name for a variable under almost
> any
> circumstances.
>
I do agree. More often than not, if I dont have a meaningful name for
a variable it is mainly because the
problem and solution are not worked out clearly in mind.
--
To unsubscribe, e-mail: [EM
On Tue, Nov 4, 2008 at 6:12 AM, <[EMAIL PROTECTED]> wrote:
> I have a string: " Confirming: yes Supplier
> Telephone: 213-923-0392"
>
> I want to split the string so that i can capture yes in $conf and
> 213-923-0392 in $tele.
>
> TIA for all the help,
>
> -ss
>
>
> --
> To unsub
On Mon, 03 Nov 2008 21:12:40 -0800, sanju.shah wrote:
> I have a string: " Confirming: yes Supplier
> Telephone: 213-923-0392"
>
> I want to split the string so that i can capture yes in $conf and
> 213-923-0392 in $tele.
>
> TIA for all the help,
What have you tried so far? W
I have a string: " Confirming: yes Supplier
Telephone: 213-923-0392"
I want to split the string so that i can capture yes in $conf and
213-923-0392 in $tele.
TIA for all the help,
-ss
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTEC
Hello,
On Nov 3, 12:45 pm, [EMAIL PROTECTED] (Andrew Curry) wrote:
> Actually using javascript it is possible although probably not
> recommended and again can not be guaranteed to work on all browsers.
even with javascript you can't catch a back-button click as such. You
can catch it via the unl
From: Rob Dixon <[EMAIL PROTECTED]>
> I have said several times that the shortcut behaviour of the logical operators
> is ugly and unfamilar to non-Unix users (yes, I know C does it, but that is a
> deficiency)
Beg your pardon??? Or maybe ... what exactly do you mean by "shortcut
behaviour"?
Yo
20 matches
Mail list logo