box-project / processor
This package is abandoned and no longer maintained.
No replacement package was suggested.
A library for processing file contents.
0.3.1
2015-06-05 14:33 UTC
Requires
- php: >=5.4
- herrera-io/object-storage: ~1.0
- kherge/file: ~1.3
- psr/log: ~1.0
Requires (Dev)
- monolog/monolog: ~1.6
- phpunit/phpunit: ~4.6
- symfony/config: 2.5.*
- symfony/dependency-injection: 2.5.*
- symfony/event-dispatcher: 2.5.*
Suggests
- monolog/monolog: For logging the processing events.
- symfony/dependency-injection: To register tagged processor services.
- symfony/event-dispatcher: Enables support for observing processing events.
This package is not auto-updated.
Last update: 2022-02-01 12:47:43 UTC
README
Processor
composer require box-project/processor
Processor simplifies the process of manipulating the contents of one or more files. With support for an event dispatcher, the process itself can also be modified or interrupted.
use Box\Component\Processor\Processor\Any\ReplaceProcessor; $processor = new ReplaceProcessor(); $processor->setReplacement('/{{\s*name\s*}}/', 'world'); $processor->setExtensions(array('txt')); // "Hello, world!" echo $processor->processContents('example.txt', 'Hello, {{ name }}!');
It may be important to note that this library is primarily designed to work with PHP archive (phar) building processes. Incompatibilities with non-phar related processes are a secondary concern and may not be patched if in conflict.
Documentation
You can find the documentation in Resources/docs
.
Requirements
kherge/file
~1.3herrera-io/object-storage
~1.0psr/log
~1.0
Suggested
monolog/monolog
~1.6symfony/dependency-injection
~2.5symfony/event-dispatcher
~2.5
License
This software is released under the MIT license.