Skip to content

Commit

Permalink
feat: add CLI.
Browse files Browse the repository at this point in the history
  • Loading branch information
smeghead committed Jan 29, 2024
1 parent 7346a79 commit aea2050
Show file tree
Hide file tree
Showing 9 changed files with 1,114 additions and 3 deletions.
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,16 @@
# php-vendor-creadits
php-vendor-creadits creates CREDITS file from LICENSE files of dependencies

## Install

### From Composer

```bash
composer require --dev smeghead/php-vendor-credits
```

## Usage

```bash
$ vendor/bin/php-class-diagram . > CREDITS
```
14 changes: 14 additions & 0 deletions bin/php-vendor-credits
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/usr/bin/env php
<?php

declare(strict_types=1);

require __DIR__ . '/../vendor/autoload.php';

use Smeghead\PhpVendorCredits\Command\CreditsCommand;
use Symfony\Component\Console\Application;

$app = new Application('php-vendor-credits', '0.0.1');
$app->add(new CreditsCommand('credits'));
$app->setDefaultCommand('credits', true);
$app->run();
4 changes: 3 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@
"name": "smeghead"
}
],
"require": {},
"require": {
"symfony/console": "^5.4"
},
"scripts": {
"test": [
"php vendor/bin/phpunit --colors test/"
Expand Down
Loading

0 comments on commit aea2050

Please sign in to comment.