我怎样才能找到我的Andr​​oid的Studio项目中所有的硬盘codeD字符串我的、有的、字符串、硬盘

2023-09-05 02:02:46 作者:痴守过去

我需要找到并提取所有的硬codeD串在我的Andr​​oid工作室(测试版)0.84项目。 我需要一个静态分析工具如发现错误做到这一点,我在一杆,让我一步通过每个消息,并提取到资源文件的字符串。甚至更好的是,如果在整个过程是自动化的。

I need to find and extract all hard coded strings in my project in Android Studio (beta) 0.84. I need a static analysis tool like Find Bugs do this for me in one shot and allow me to step through each message and extract the string to resource files. Even better would be if the entire process is automated.

在机器人工作室(测试版)0.84文件/设置/ FindBugs的-IDEA显示国际化作为在报告选项卡的选项。 但我只是不知道如何使它发挥作用。

In Android Studio (beta) 0.84 the File / Setting /FindBugs-IDEA shows I18N as an option under Reporting tab. But I just cannot figure out how to make it work.

感谢您的任何建议。

推荐答案

进入分析>运行检验所名称...,然后键入硬codeD文本。运行一个对你的整个项目,你应该得到的检查结果面板将显示硬盘codeD文本实例。

Go to "Analyze > Run Inspection By Name...", and type "Hardcoded text". Run that one against your whole project, and you should get an inspection results panel that will show the hardcoded text instances.

您也可以去到Android工作室> preferences>检查>硬codeD文本,并指定究竟如何运行,以及什么(如果有的话)特殊情况下被排除在检查。

You can also go to Android Studio > Preferences > Inspections > Hardcoded text and specify exactly how it runs, and what (if any) special cases are excluded from inspection.