简体   繁体   中英

Search and replace using a regex in Sublime Text

How to do a search and replace with Sublime Text, so it finds "(wildcard)" ?

I want to do a simple find and replace to get curly quotes, I expect that this can be done using regex.

Thanks :)

If you're looking to make curly quotes into straight quotes, then can you just replace , ' , , and ' with " , ' , " , and ' , respectively? But maybe that is not your aim. You should be able to use the curly quotes "literally" in your regex, eg

“(.*?)”

EDIT:

Ah, so you want to convert straight quotes to curly quotes. In that case, try replacing

"([^"]*)"

with

“$1”

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM