EscolaLMS/API

View on GitHub
deptrac.php

Summary

Maintainability
A
0 mins
Test Coverage
<?php


$paths = glob("./vendor/escolalms/*");

$a = [
    'deptrac' => [
        'paths' => [
            './vendor/escolalms'
        ],
        'layers' => []
    ]
];

foreach ($paths as $path) {
    if (strpos($path, "core")) {
        continue;
    }
    $a['deptrac']['layers'][] = [
        'name' => basename($path),
        'collectors' => [[
            'type' => 'directory',
            'value' => $path
        ]]

    ];
}

yaml_emit_file('deptrac-modules.yaml', $a);