PHP code example of innmind / silent-cartographer

1. Go to this page and download the library: Download innmind/silent-cartographer library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

innmind / silent-cartographer example snippets


use Innmind\CLI\{
    Main,
    Environment,
};
use Innmind\OperatingSystem\OperatingSystem;
use Innmind\Url\Path;
use function Innmind\SilentCartographer\bootstrap;

new class extends Main {
    protected function main(Environment $env, OperatingSystem $os): void
    {
        $os = bootstrap($os)['cli'](Path::of(__DIR__));
        // then use the $os variable like you would normally do
    }
}