6f2cb7e69d4d7803edbe8c48f07e93344d62cd11
NIH PHP Command Builder
Simple command builder inspired by rust's std library.
<?php
use Nih\CommandBuilder\Command;
use Nih\CommandBuilder\Stdio;
require_once __DIR__ . '/vendor/autoload.php';
$child = (new Command('cat'))
->stdin(Stdio::piped())
->stdout(Stdio::piped())
->spawn();
$child->stdin?->write('Hello, this is pretty cool.');
$output = $child->output();
echo $output->stdout;
// Hello, this is pretty cool.
Languages
PHP
99.2%
Makefile
0.8%