I was looking at this again and I think I now understand what you're asking 
for....You don't want to have to write the regex to find the text before 
what you're wanting to put into your delimited result, but you also would 
like it to put the result in front of the whole string. Have I got that 
right? If so, I don't think you can do that with a regex...err, should I 
say "I certainly don't know how to pull that one off".

On Wednesday, October 2, 2019 at 8:01:34 AM UTC-4, Dave R wrote:
>
> I was hoping for an alternative to the & in the replacement strung that 
> means ‘entire source line’ but this works perfectly. 
>
> Thanks! 
>
> Cheers, 
>
> Dave 
>
> > On 2-October-2019, at 7:45 AM, ThePorgie <thep...@gmail.com 
> <javascript:>> wrote: 
> > 
> > Would something like this be what you're looking for? 
> > 
> > .+?/2019/[019]+/([0-9]+)[_.]([0-9]+)-([a-zA-Z]+).* 
> > 
> > This will give you the same result with your replacement string. 
> > 
> > \3 \1, NEN PDF, \1/\2/01, & 
> > 
> > The ".+?" tells the expression to find everything till the rest of the 
> expression that remains matches. If anything is off in the rest of the 
> expression it won't find a result in the string being searched. 
> > 
> > Is that what you're looking for? 
> > 
> > 
> > On Tuesday, October 1, 2019 at 2:05:05 PM UTC-4, Dave R wrote: 
> > Hi folks, 
> > 
> > I have a regex that takes a url apart and makes me a csv of the 
> components: 
> > 
> > Regex: 
> > http://ftp\.newedinburgh\.ca/wp-content/uploads/2019/[019]+/([0-9]+)[_.]([0-9]+)-([a-zA-Z]+).*
> >  
>
> > 
> > and the replacement: 
> > \3 \1, NEN PDF, \1/\2/01, & 
> > 
> > which gives, for example: 
> > April 1976, NEN PDF, 1976/04/01, 
> http://ftp.newedinburgh.ca/wp-content/uploads/2019/09/1976_04-April-New-Edinburgh-News_web.pdf
>  
> > 
> > I am wondering if there is a way to leave the http…2019 out of the regex 
> and, instead of the & (which matches entire regex selection) in the 
> replacement, use something else to represent the entire source line. 
> > 
> > As you can see i’ve found a solution.. but I am always curious to see if 
> there is a simpler way. 
> > 
> > Cheers, 
> > 
> > Dave 
> > 
> > -- 
> > This is the BBEdit Talk public discussion group. If you have a 
> > feature request or need technical support, please email 
> > "sup...@barebones.com <javascript:>" rather than posting to the group. 
> > Follow @bbedit on Twitter: <https://twitter.com/bbedit> 
> > --- 
> > You received this message because you are subscribed to the Google 
> Groups "BBEdit Talk" group. 
> > To unsubscribe from this group and stop receiving emails from it, send 
> an email to bbe...@googlegroups.com <javascript:>. 
> > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/bbedit/3aea19a9-d72e-4afb-ad16-8cf4e336e9b7%40googlegroups.com.
>  
>
>
>

-- 
This is the BBEdit Talk public discussion group. If you have a 
feature request or need technical support, please email
"supp...@barebones.com" rather than posting to the group.
Follow @bbedit on Twitter: <https://twitter.com/bbedit>
--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bbedit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bbedit/e7b8c06b-5214-4b53-8e8c-e8435bb677b9%40googlegroups.com.

Reply via email to