Added bin to list datasets

This commit is contained in:
Chris 2022-10-30 18:38:43 +01:00
parent 493284b982
commit c3e651440f
2 changed files with 22 additions and 1 deletions

20
bin/dataset-info Executable file
View File

@ -0,0 +1,20 @@
#!/usr/bin/env php
<?php
foreach ([
__DIR__."/../vendor",
__DIR__."/../../../vendor"
] as $dir) {
if (file_exists($dir."/autoload.php")) {
require_once $dir."/autoload.php";
echo $dir."\n";
}
}
$datasetManager = new NoccyLabs\Dataset\DatasetManager();
$datasets = $datasetManager->getAvailableDatasets();
foreach ($datasets as $dataset) {
echo $dataset->getIdentifier()."\n";
}

View File

@ -14,5 +14,6 @@
"email": "cvagnetoft@gmail.com"
}
],
"require": {}
"require": {},
"bin": [ "bin/dataset-info" ]
}