Skip to content

A tool for attempting to identify unreferenced files and unused functions in a PHP codebase.

License

Notifications You must be signed in to change notification settings

fuzzy76/phpunused

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

phpunused

A tool for attempting to identify unreferenced files and unused functions in a PHP codebase.

This is by no means exact, and the output is a report that should be checked manually.

Requirements

  • PHP 5.4 (probably)
  • grep (so POSIX?)

Usage

Run from the top directory of the project you want to check. Like so:

php ~/repos/phpunused/phpunused.php

State

This is a quick hack to help me analyze a code base. Pull requests are welcome, but apart from that, new features are unlikely.

Possible improvements

  • Find references in .js files (ajax calls and such)
  • Ignore function references in commented out lines
  • Recognise prematurely ended functions (return/exit in front of code)

About

A tool for attempting to identify unreferenced files and unused functions in a PHP codebase.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages