Determining which PHP source files are not used

好久不见. 提交于 2019-12-12 11:00:43

问题


I have a large web app, and I think there are a bunch of old files that are no longer being used, is there an app which can tell me what these files are?


回答1:


There is also the Dead Code Detector (DCD). It finds functions that are never called, which may help to clean up even the files you keep in production.




回答2:


You should be able to start with your web server logs. These will show you which files ARE being used. From there you should be able to track down a good number of the files those reference. Don't know of a good way to find out which aren't being used, only those that are.




回答3:


I think you need to check out the project management tools available for php.

You can have a look at phpUnderControl (http://www.phpundercontrol.org/about.html) and CruiseControl (you can google it).

You can also use a tool (i.e and IDE) that will give a Code Coverage Report.



来源:https://stackoverflow.com/questions/1811421/determining-which-php-source-files-are-not-used

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!