rapidez / composer-template-diff-plugin
Composer plugin for template override hash synchronization
Package info
github.com/rapidez/composer-template-diff-plugin
Type:composer-plugin
pkg:composer/rapidez/composer-template-diff-plugin
Requires
- composer-plugin-api: ^2.0
Requires (Dev)
- composer/composer: ^2.0
- phpstan/extension-installer: ^1.4
- phpstan/phpstan: ^2.2
This package is auto-updated.
Last update: 2026-08-11 08:34:57 UTC
README
This composer plugin will create hashes of the original template in published templates after a composer update.
This way you have a clear indication that a template you have overwritten has been changed.
It will add a {{-- vendor-hash:VENDOR_FILE_MD5_HASH --}} comment to the top of your blade files.
It will use the views publishables for this so make sure your views are publishable under the views tag.
Installation
composer require (--dev) rapidez/composer-template-diff-plugin
Usage
You can also run manually update the hashes with:
composer update-vendor-hashes`
This will also automatically run after updating any packages.
Configure automatic plugin execution
Automatic execution (after composer update) can be disabled explicitly with:
RAPIDEZ_TEMPLATE_DIFF_DISABLED=1
When RAPIDEZ_TEMPLATE_DIFF_DISABLED is not set, automatic execution is enabled only when APP_ENV is local
Manual execution with composer update-vendor-hashes always runs and does not use these automatic plugin toggle rules.
License
GNU General Public License v3. Please see License File for more information.