Text factory can help you to replace first only? Il giorno gio 7 mag 2026 alle 19:26 Jason Davies <[email protected]> ha scritto:
> But this would replace every instance of "<section>", where he wants to > replace only the first one... > > Cheers, > > Jason > > On 7 May 2026, at 18:13, Massimo Rainato wrote: > > i hope that help, > use only <section> as search > use <section id="main_content">\1 > > page 221 manuale / in replacement patterns > > \N nth captured substring, first only. > > [mrai64] > > Il giorno 7 mag 2026, alle ore 18:59, [email protected] ha scritto: > > You can do this with a search/replace. The first pattern matches the > contents of the file before the first <section>. [\s\S] is used instead of > period so it will match without finding the next repetition of the pattern. > The question mark on the first grouping makes it match the first <section>. > > Search pattern: ([\s\S]*?)<section>([\s\S]*) > > Replace pattern: \1<section id=“main_content">\2 > > [fletcher] > > On May 7, 2026, at 6:29 AM, Neil Faiman [email protected] wrote: > > Well, at least I read the fine manual and saved myself the humiliation of > publicly asking whether there was a way to selectively search in the set of > files that matched a previous multi-file search. (Of course there is. Just > select the previous search results from the “Results Browsers” list in the > “Search in:” chooser.) > > But I couldn’t find this one in the manual. I have a bunch of HTML files. > Some of them have multiple <section> elements. I want to add a property to > the first <section> tag in each file. I.e., before > > <section> > some content > <section> > inner content > </section> > </section> > <section> > more content > </section> > > and after: > > <section id=“main_content"> > some content > <section> > inner content > </section> > </section> > <section> > more content > </section> > > But the only choices seem to be replace al or replace none. Is there a > clever hack to solve this (or better, another feature I’ve overlooked? > > Thanks, > Neil Faiman > -- > This is the BBEdit Talk public discussion group. If you have a feature > request or believe that the application isn't working correctly, please > email "[email protected]" rather than posting here. Follow @bbedit on > Mastodon: https://mastodon.social/@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 [email protected]. > To view this discussion visit > https://groups.google.com/d/msgid/bbedit/0E76497B-0BB8-4AB2-A2B2-C595E261F46F%40faiman.org > . > > -- > This is the BBEdit Talk public discussion group. If you have a feature > request or believe that the application isn't working correctly, please > email "[email protected]" rather than posting here. Follow @bbedit on > Mastodon: https://mastodon.social/@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 [email protected]. > To view this discussion visit > https://groups.google.com/d/msgid/bbedit/E3C3CFD9-09EE-4CE3-8854-7238E8446121%40cumuli.com > . > > -- > This is the BBEdit Talk public discussion group. If you have a feature > request or believe that the application isn't working correctly, please > email "[email protected]" rather than posting here. Follow @bbedit on > Mastodon: https://mastodon.social/@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 [email protected]. > To view this discussion visit > https://groups.google.com/d/msgid/bbedit/971CCAB7-ED4E-4656-8B95-9E37673660D5%40gmail.com > . > > https://orcid.org/0000-0002-7213-2147 > > Davies, J. P. (2025). Landscapes of Liminality: Towards a Map > <https://pressbooks.bccampus.ca/thresholdconceptsconference/chapter/landscapes-of-liminality-towards-a-map/>. > In A. S. Webb (Ed.), 2025 *New Horizons in Threshold Concepts (Vancouver > B.C.)* <https://pressbooks.bccampus.ca/thresholdconceptsconference/>. > > Davies, J. P. et al (eds.). (2024). *Threshold Concepts in the Moment* > <https://doi.org/10.1163/9789004680661>. Brill. > > Mosurinjon S., Davies. J. P. (2024) 'Secularism as a Universalising > Threshold Concept' <https://doi.org/10.1163/9789004680661_006> in Davies > et al (2024), 72--85. > > -- > This is the BBEdit Talk public discussion group. If you have a feature > request or believe that the application isn't working correctly, please > email "[email protected]" rather than posting here. Follow @bbedit on > Mastodon: <https://mastodon.social/@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 [email protected]. > To view this discussion visit > https://groups.google.com/d/msgid/bbedit/A6BAC9FB-2484-44CF-ABE1-7BD4366106C1%40gmail.com > <https://groups.google.com/d/msgid/bbedit/A6BAC9FB-2484-44CF-ABE1-7BD4366106C1%40gmail.com?utm_medium=email&utm_source=footer> > . > -- This is the BBEdit Talk public discussion group. If you have a feature request or believe that the application isn't working correctly, please email "[email protected]" rather than posting here. Follow @bbedit on Mastodon: <https://mastodon.social/@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 [email protected]. To view this discussion visit https://groups.google.com/d/msgid/bbedit/CAK3epCFpT3dDjFQ_%2BwTwoY45ADS0oWsf8KCGEjx6dW%2BN8FzD%2BQ%40mail.gmail.com.
