Download the PHP package scheb/tombstone without Composer
On this page you can find all versions of the php package scheb/tombstone. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download scheb/tombstone
More information about scheb/tombstone
Files in scheb/tombstone
Package tombstone
Short Description Dead code detection with tombstones for PHP
License MIT
Homepage https://github.com/scheb/tombstone
Informations about the package tombstone
scheb/tombstone
Implements the concept of tombstones for dead code detection in PHP.
The library provides you with a toolbox to place, track and evaluate tombstones in your code.
What are Tombstones?
To get the basic idea, watch David Schnepper's 5 minute talk from Velocity Santa Clara 2014.
When you want to identify and clean-up dead code in a project, static code analysis tools are the weapon of choice. But these tools have some limitations, especially in a dynamic language like PHP:
- They can only tell you, if a piece of code is referenced, not if it's actually used
- They cannot resolve dynamic or generated call paths
Tombstones provide a way to track if a piece of code is actually invoked. They are executable markers in your code, that you can place where you suspect dead code. Then, you collect tombstone invocations on production. After a while, the logs will tell you, which tombstones are dead and which ones aren't (the so called "vampires").
Installation
The library consists of multiple components, that need to be installed and configured independently:
Read how to install scheb/tombstone-logger
for placing and logging tombstones in your code.
Read how to install scheb/tombstone-analyzer
, which takes log data from
scheb/tombstone-logger
to generate reports in various formats. For example an HTML report:
Security
For information about the security policy and know security issues, see SECURITY.md.
Contributing
Want to contribute to this project? See CONTRIBUTING.md.
License
This software is available under the MIT license.
Acknowledgments
The library is heavily inspired by Nestoria.com's implementation of the tombstone concept.
Thanks to Jordi Boggiano for creating Monolog, from where I lend the handler/formatter concept.
The tombstone graphic is based on a licensed illustration by "lemonadeserenade".
Support Me
I'm developing this library since 2015. I love to hear from people using it, giving me the motivation to keep working on my open source projects.
If you want to let me know you're finding it useful, please consider giving it a star ⭐ on GitHub.
If you love my work and want to say thank you, you can help me out for a beer 🍻️ via PayPal.
All versions of tombstone with dependencies
ext-json Version *
ext-dom Version *
nikic/php-parser Version ^4.0|^5.0
phpunit/php-text-template Version ^1.2.1|^2.0|^3.0
psr/log Version ^1.0|^2.0|^3.0
symfony/finder Version ^3.4|^4.1|^5.0|^6.0|^7.0
symfony/config Version ^3.4|^4.0|^5.0|^6.0|^7.0
symfony/console Version ^3.4|^4.0|^5.0|^6.0|^7.0
symfony/yaml Version ^3.4|^4.0|^5.0|^6.0|^7.0