PHP code example of innmind / ssh-key-provider
1. Go to this page and download the library: Download innmind/ssh-key-provider 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 / ssh-key-provider example snippets
use Innmind\OperatingSystem\Factory;
use Innmind\SshKeyProvider\{
Cache,
Merge,
Local,
Github,
};
use Innmind\Url\Path;
$os = Factory::build();
$provide = Cache::of(
Merge::of(
Local::of(
$os->filesystem()->mount(Path::of($_SERVER['USER'].'/.ssh/')),
),
Github::of(
$os->remote()->http(),
'GithubUsername',
),
),
);
$sshKeys = $provide();