Regex that worked on Sublime not working on Pycharm

后端 未结 1 1465
难免孤独
难免孤独 2021-01-15 02:06

Ok so, in Sublime Text I can use this Find/Replace regex:

find: (src|href)=\"(assets\\/.+?)\"
replace: \\1=\"{% static \'\\2\' %}\"

To repl

1条回答
  •  轻奢々
    轻奢々 (楼主)
    2021-01-15 02:46

    As described in the PyCharm documentation, in PyCharm you need to use $1 rather than \1 to refer to a group in the replacement expression.

    0 讨论(0)
提交回复
热议问题