sweetchuck / git
Git related helpers classes.
1.x-dev
2024-12-22 14:31 UTC
Requires
- php: >=8.3
Requires (Dev)
- ext-dom: *
- ext-json: *
- nuvoleweb/robo-config: ^3.0
- phpstan/phpstan: ^1.10
- phpunit/phpunit: ^11.0
- squizlabs/php_codesniffer: ^3.5
- sweetchuck/git-hooks: 2.x-dev
- sweetchuck/robo-git: 4.x-dev
- sweetchuck/robo-phpcs: 4.x-dev
- sweetchuck/robo-phpstan: 3.x-dev
- symfony/error-handler: ^7.0
This package is auto-updated.
Last update: 2024-12-23 14:49:02 UTC
README
stdInput reader
stdInput reader - Supported Git hooks
stdInput reader - Usage
.git/hooks/pre-receive
#!/usr/bin/env php <?php use Sweetchuck\Git\StdInputReader\PreReceiveReader; $reader = new PreReceiveReader(\STDIN); foreach ($reader as $item) { echo 'Old value: ', $item->oldValue, \PHP_EOL; echo 'New value: ', $item->newValue, \PHP_EOL; echo 'Ref name: ', $item->refName, \PHP_EOL; echo '-----------', \PHP_EOL; }