Re: tip: that annoying character at the end

2018-09-14 Thread Brad Gilbert
On Fri, Sep 14, 2018 at 10:11 PM ToddAndMargo wrote: > > On 09/14/2018 07:34 PM, Brad Gilbert wrote: > > $x ~~ s/ <:Cc>+ $ //; > > What exactly is <:Cc> again? < and > inside of a regular expression is for advanced features If the first character is : then it knows to look for Unicode

Re: tip: that annoying character at the end

2018-09-14 Thread ToddAndMargo
On 09/14/2018 07:34 PM, Brad Gilbert wrote: $x ~~ s/ <:Cc>+ $ //; What exactly is <:Cc> again?

Re: tip: that annoying character at the end

2018-09-14 Thread ToddAndMargo
On 09/14/2018 07:34 PM, Brad Gilbert wrote: On Fri, Sep 14, 2018 at 7:49 PM ToddAndMargo wrote: On Fri, Sep 14, 2018 at 5:22 PM ToddAndMargo wrote: Hi All, A tip to share. I work a lot with downloaded web pages. I cut out things like revision numbers and download locations. One of the

Re: tip: that annoying character at the end

2018-09-14 Thread Brad Gilbert
On Fri, Sep 14, 2018 at 7:49 PM ToddAndMargo wrote: > > > On Fri, Sep 14, 2018 at 5:22 PM ToddAndMargo wrote: > >> > >> Hi All, > >> > >> A tip to share. > >> > >> I work a lot with downloaded web pages. I cut > >> out things like revision numbers and download > >> locations. > >> > >> One of

Re: tip: that annoying character at the end

2018-09-14 Thread ToddAndMargo
On Fri, Sep 14, 2018 at 5:22 PM ToddAndMargo wrote: Hi All, A tip to share. I work a lot with downloaded web pages. I cut out things like revision numbers and download locations. One of the things that use to drive me a bit nuts was that web pages can come with all kind of weird line

Re: tip: that annoying character at the end

2018-09-14 Thread Brad Gilbert
You can just remove the control characters my $x="abc.zip"~chr(7)~chr(138); $x .= subst(/<:Cc>+ $/,''); say $x; Note that 13 is carriage return and 10 is newline If the only ending values are (13,10), 13, or 10 you can use .chomp to remove them my $x="abc.zip"~chr(13)~chr(10);