PHP Classes

Yii2 Dependency Finder: Find dependencies of project that uses Yii2

Recommend this page to a friend!
  Info   Documentation   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not yet rated by the usersTotal: 17 All time: 11,338 This week: 40Up
Version License PHP version Categories
yii2-dependency-find 1.0MIT/X Consortium ...7.4Debug, Tools, Files and Folders, Lang..., P...
Description 

Author

This package can find dependencies of project that uses Yii2.

It can scan the files of a project that is in a given path and finds the dependencies of that project on Yii2 modules.

The package can output the depedencies that it finds in text or CVS formats.

Innovation Award
PHP Programming Innovation award nominee
March 2023
Number 8
Complex projects are often made of packages that provide services to others to reuse the work done by their developers, thus reducing the time the projects can take to develop.

Knowing the dependencies of projects on other packages can be helpful for developers to determine what packages their projects depend on.

This package implements means to find the dependencies of projects that use the Yii2 framework.

Manuel Lemos
Picture of Smoren  Freelight
  Performance   Level  
Name: Smoren Freelight <contact>
Classes: 38 packages by
Country: Russian Federation Russian Federation
Age: 35
All time rank: 280978 in Russian Federation Russian Federation
Week rank: 47 Up6 in Russian Federation Russian Federation Up
Innovation award
Innovation award
Nominee: 16x

Documentation

yii2-dependency-finder

Extension for finding horizontal dependencies of Yii2 modules

How to install to Yii2 project

composer require smoren/yii2-dependency-finder

Usage

use Smoren\Yii2\DependencyFinder\Finders\ProjectDependencyFinder;
use Smoren\Yii2\DependencyFinder\Structs\Path;
use Smoren\Yii2\DependencyFinder\Writers\ShortTxtWriter;
use Smoren\Yii2\DependencyFinder\Writers\ShortTxtWriter;
use Smoren\Yii2\DependencyFinder\Writers\DetailedTxtWriter;
use Smoren\Yii2\DependencyFinder\Writers\CsvWriter;

$dependencyFinder = new ProjectDependencyFinder(new Path(dirname(__DIR__)));
$dependencyCollection = $dependencyFinder->find();

print_r($dependencyCollection->getSummary());

$writer = new ShortTxtWriter(new Path(dirname(__DIR__), 'logs/dependencies_short.txt'));
$writer->write($dependencyCollection);

$writer = new DetailedTxtWriter(new Path(dirname(__DIR__), 'logs/dependencies_detailed.txt'));
$writer->write($dependencyCollection);

$writer = new CsvWriter(new Path(dirname(__DIR__), 'logs/dependencies.csv'));
$writer->write($dependencyCollection);

  Files folder image Files (22)  
File Role Description
Files folder imagesrc (6 directories)
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file LICENSE Lic. License text
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files (22)  /  src  
File Role Description
Files folder imageCollections (2 files)
Files folder imageFinders (3 files)
Files folder imageInterfaces (6 files)
Files folder imageStructs (2 files)
Files folder imageWalkers (2 files)
Files folder imageWriters (4 files)

  Files folder image Files (22)  /  src  /  Collections  
File Role Description
  Plain text file ModuleDependencyCollection.php Class Class source
  Plain text file ProjectDependencyCollection.php Class Class source

  Files folder image Files (22)  /  src  /  Finders  
File Role Description
  Plain text file FileDependencyFinder.php Class Class source
  Plain text file ModuleDependencyFinder.php Class Class source
  Plain text file ProjectDependencyFinder.php Class Class source

  Files folder image Files (22)  /  src  /  Interfaces  
File Role Description
  Plain text file CollectionInterface.php Class Class source
  Plain text file FinderInterface.php Class Class source
  Plain text file ModuleInterface.php Class Class source
  Plain text file PathInterface.php Class Class source
  Plain text file WalkerInterface.php Class Class source
  Plain text file WriterInterface.php Class Class source

  Files folder image Files (22)  /  src  /  Structs  
File Role Description
  Plain text file Module.php Class Class source
  Plain text file Path.php Class Class source

  Files folder image Files (22)  /  src  /  Walkers  
File Role Description
  Plain text file ProjectModuleWalker.php Class Class source
  Plain text file ProjectTreeWalker.php Class Class source

  Files folder image Files (22)  /  src  /  Writers  
File Role Description
  Plain text file BaseFileWriter.php Class Class source
  Plain text file CsvWriter.php Class Class source
  Plain text file DetailedTxtWriter.php Class Class source
  Plain text file ShortTxtWriter.php Class Class source

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 100%
Total:17
This week:0
All time:11,338
This week:40Up