Find all strings in python code files

后端 未结 6 1239
清歌不尽
清歌不尽 2021-01-11 23:26

I would like to list all strings within my large python project.

Imagine the different possibilities to create a string in python:

mystring = \"hello         


        
6条回答
  •  耶瑟儿~
    2021-01-11 23:52

    Are you asking about the I18N utilities in Python?

    http://docs.python.org/library/gettext.html#internationalizing-your-programs-and-modules

    There's a utility called po-utils (formerly xpot) that can help with this.

    http://po-utils.progiciels-bpi.ca/README.html

提交回复
热议问题