in reply to backtick iterpolation issue

How do you populate $playListRow? Can you show it's contents through
use Data::Dumper; $Data::Dumper::Useqq = 1; print Dumper($playListRow);
لսႽ† ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ

Replies are listed 'Best First'.
Re^2: backtick iterpolation issue
by idlehands (Initiate) on Jul 01, 2015 at 13:43 UTC
     $VAR1 = "\\/Volumes\\/public_files\\/music\\/The\\ Lexicon\\ Of\\ Love\\/4\\.Tears\\ Are\\ Not\\ Enough\\.mp3\\\r"; playlist row is just a line pulled from an itunes m3u file, though I filtered out the comments from the m3u file:
    open(my $fh2, '<:encoding(UTF-8)',$playlistName) or die "Could not open playlist file '$playlistName $! +"; while( my $playListRow = <$fh2>){ chomp $playListRow; if($playListRow =~ /^\s*#/){ next;} else{ # print "$playListRow\n"; $playListRow = quotemeta($playListRow); my $lscom = "ls $playListRow 2>&1";
      Replace chomp with
      $playListRow =~ tr/\xd\xa//d;

      It should remove all the newlines, CR/LF or LF style.
      Update: You might need to verify how file names containing newlines are represented in the list.

      لսႽ† ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ