Find and Replace - Non-capture group regex

Hey all, I’m trying to get the Rust Crate Regex down for a find and replace.
An example:

[sound:588-어디-sentence.mp3]
[sound:588-어디.mp3]

[sound:naver-c35562aa-4f003c75-eb3601bf-47c57db3-c958be69.mp3]

[sound:naver-c426ef42-8f2a55e6-97a3268a-feb30459-47932cba.mp3]

Needs to become (remove all naver sound references):

[sound:588-어디-sentence.mp3]
[sound:588-어디.mp3]

My regex is currently as follows, I am trying a non-capture group:
(?:\n^\[sound:naver-.*\.mp3\]$)

reg ex 101link :

regex101 dot com/r/LjwL21/1

When I click replace, the substitution does not occur. Do I need to capture the text I want instead? Thank you.

Newlines are likely HTML BR tags or divs. I suggest you not worry about that part, and just try to replace the sound tag itself with something like

\[sound:naver-.*?\.mp3\]
1 Like

Thanks so much Damien! As always, you saved me a lot of time and hassle. Appreciate the assistance.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.