-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 49a8dbe
Showing
51 changed files
with
6,380 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: PHP Composer | ||
|
||
on: | ||
push: | ||
branches: [ main ] | ||
pull_request: | ||
branches: [ main ] | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Validate composer.json and composer.lock | ||
run: composer validate --strict | ||
|
||
- name: Cache Composer packages | ||
id: composer-cache | ||
uses: actions/cache@v2 | ||
with: | ||
path: vendor | ||
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-php- | ||
- name: Install dependencies | ||
run: composer install --prefer-dist --no-progress | ||
|
||
- name: Run test suite | ||
run: composer run-script test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
.idea | ||
.phpunit.result.cache | ||
.composer/ | ||
vendor/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2019 minicli | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# Packager | ||
|
||
[![Packager](https://preview.dragon-code.pro/laravel-ready/packager.svg?brand=laravel)](https://github.com/laravel-readypackager) | ||
|
||
[![Stable Version][badge_stable]][link_packagist] | ||
[![Unstable Version][badge_unstable]][link_packagist] | ||
[![Total Downloads][badge_downloads]][link_packagist] | ||
[![License][badge_license]][link_license] | ||
|
||
## 📂 About | ||
|
||
Currently, Laravel does not provide a package creation/generation/wizard tool. Packager is a package creation tool package. You can create laravel packages with this tool on CLI easily. Generally, we use singleton packages for developing laravel packages, or we often craft the packages manually. This takes some time and it process is open to errors. Packager generates all files from templates and accelerates the development phase. | ||
|
||
Packager follows [PSR](https://www.php-fig.org/psr/) standards, [laravel API](https://laravel.com/api/9.x/) and laravel [folder structure](https://github.com/laravel/laravel). | ||
|
||
## 📦 Installation | ||
|
||
Get via composer | ||
|
||
`composer require laravel-ready/packager --dev` | ||
|
||
or install globally | ||
|
||
`composer global require laravel-ready/packager --dev` | ||
|
||
[badge_downloads]: https://img.shields.io/packagist/dt/laravel-ready/packager.svg?style=flat-square | ||
|
||
[badge_license]: https://img.shields.io/packagist/l/laravel-ready/packager.svg?style=flat-square | ||
|
||
[badge_stable]: https://img.shields.io/github/v/release/laravel-ready/packager?label=stable&style=flat-square | ||
|
||
[badge_unstable]: https://img.shields.io/badge/unstable-dev--main-orange?style=flat-square | ||
|
||
[link_license]: LICENSE | ||
|
||
[link_packagist]: https://packagist.org/packages/laravel-ready/packager |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
#!/usr/bin/env php | ||
<?php | ||
|
||
if (php_sapi_name() !== 'cli') { | ||
exit; | ||
} | ||
|
||
require __DIR__ . '/../vendor/autoload.php'; | ||
|
||
use Minicli\App; | ||
use Minicli\Exception\CommandNotFoundException; | ||
|
||
$app = new App([ | ||
'app_path' => __DIR__ . '/../src/Command', | ||
'theme' => '', | ||
'debug' => true, | ||
]); | ||
|
||
try { | ||
echo __DIR__; | ||
$app->runCommand($argv); | ||
} catch (CommandNotFoundException $notFoundException) { | ||
$app->getPrinter()->error("Command Not Found."); | ||
|
||
return 1; | ||
} catch (Exception $exception) { | ||
if ($app->config->debug) { | ||
$app->getPrinter()->error("An error occurred:"); | ||
$app->getPrinter()->error($exception->getMessage()); | ||
} | ||
|
||
return 1; | ||
} | ||
|
||
return 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
{ | ||
"name": "laravel-ready/packager", | ||
"description": "Minicli Application Template", | ||
"version": "1.0.0", | ||
"license": "MIT", | ||
"homepage": "https://github.com/minicli/application", | ||
"keywords": ["cli","command-line", "template"], | ||
"autoload": { | ||
"psr-4": { | ||
"LaravelReady\\Packager\\": "src/" | ||
} | ||
}, | ||
"require": { | ||
"minicli/minicli": "^3.0", | ||
"minicli/command-help": "^0.1.0", | ||
"illuminate/support": "v8.83.18", | ||
"illuminate/filesystem": "v8.83.18", | ||
"nikic/php-parser": "^4.14", | ||
"phpstan/phpstan": "^1.8.0" | ||
}, | ||
"require-dev": { | ||
"pestphp/pest": "^1.21" | ||
}, | ||
"scripts": { | ||
"test" : ["pest"] | ||
}, | ||
"config": { | ||
"allow-plugins": { | ||
"pestphp/pest-plugin": true | ||
} | ||
}, | ||
"bin": [ | ||
"bin/packager" | ||
] | ||
} |
Oops, something went wrong.