David Moreno Garza schreef:
> open FILE, 'H:\My Music\folderlist.txt';
> open DEST, '> H:\My Music\artists.txt';
> foreach my $line(readline FILE) {
> chomp;
> print DEST $1."\n" if $line =~ /\s*(.*)$/;
> }
> close FILE;
> close DEST;
Wouldn't it be great if, especially on this list, such
On Thu, 2007-01-18 at 21:42 -0500, Mathew Snyder wrote:
> Citlali had provided a regex that almost did what I wanted and then David gave
> me one that did exactly what I wanted.
Yay! We learn from everybody :-)
David.
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail
Rob Dixon wrote:
> Mathew Snyder wrote:
>> Rob Dixon wrote:
>>> Mathew wrote:
I have a file with a list of subfolders. The list was created using
dir
and each entry is like thus:
12/12/2005 04:38 AM A Perfect Circle
I then created a simple script th
Mathew Snyder wrote:
Rob Dixon wrote:
Mathew wrote:
I have a file with a list of subfolders. The list was created using dir
and each entry is like thus:
12/12/2005 04:38 AM A Perfect Circle
I then created a simple script that I hoped would eliminate everything
prior to the last
Rob Dixon wrote:
> Mathew wrote:
>> I have a file with a list of subfolders. The list was created using dir
>> and each entry is like thus:
>>
>> 12/12/2005 04:38 AM A Perfect Circle
>>
>> I then created a simple script that I hoped would eliminate everything
>> prior to the last bit
Mathew wrote:
I have a file with a list of subfolders. The list was created using dir
and each entry is like thus:
12/12/2005 04:38 AM A Perfect Circle
I then created a simple script that I hoped would eliminate everything
prior to the last bit of text which follows the big space
On Thu, 2007-01-18 at 11:44 -0500, Mathew wrote:
> open FILE, "H:\My Music\folderlist.txt";
>
> foreach my $line (readline FILE) {
> $line =~ s/^.*\s//g;
> open FILE2, "H:\My Music\artists.txt";
> print FILE2 $line . "\n";
> close FILE2;
> }
>
> close FILE;
I'd go w
On 1/18/07, Mathew <[EMAIL PROTECTED]> wrote:
open FILE, "H:\My Music\folderlist.txt";
Use forward slashes instead of backslashes in filename strings, even
on Windows. (Or, if you mean a true backslash, use two of them; a
single backslash is always magical in Perl.) And check the return
value
also keep open and close outside the loop.
you overwriting previously written lines.
open FILE2,"$file";
foreach @lines
{
print FILE2 $_;
}
close FILE2
cheers
On 1/18/07, Mathew <[EMAIL PROTECTED]> wrote:
Thanks. That likely will help. However, I still can't even get it to
perform any action
Thanks. That likely will help. However, I still can't even get it to
perform any action. I have it set to print to the screen right now but
it isn't creating any output.
Mathew
Guerrero, Citlali (GE, Corporate, consultant) wrote:
> Hi Mathew :
>
> This is what your regexp ($line =~ s/^.*\
10 matches
Mail list logo