https://github.com/autoframe/cli-tools
https://github.com/autoframe/cli-tools
Last synced: 11 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/autoframe/cli-tools
- Owner: autoframe
- License: mit
- Created: 2024-04-26T18:28:42.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-04-26T19:54:15.000Z (about 2 years ago)
- Last Synced: 2025-04-28T10:14:30.706Z (about 1 year ago)
- Language: PHP
- Size: 5.86 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Autoframe is a low level framework that is oriented on SOLID flexibility
[](https://opensource.org/license/bsd-3-clause/)

[](https://packagist.org/packages/autoframe/components-socket-cache)
*Cli Prompt, Text styles Bold, Italic, Blink, Underline, Text colors, Background colors...*
**Examples** https://prnt.sc/-ns-4QpB3NYl

```php
`AfrCliPromptMenu`
use Autoframe\CliTools\AfrCliPromptMenu;
if (!AfrCliPromptMenu::insideCli()) {
echo 'The script does not run inside CLI!' . PHP_EOL;
return;
}
$options = [
'Mercedes',
'Audi',
'Porsche',
];
$user_choice = AfrCliPromptMenu::promptMenu(
"Select your dream car",
$options,
$options[1]
);
print PHP_EOL . "You chose: '$user_choice'\n";
```
---
```php
`AfrCliTextColors`
use Autoframe\CliTools\AfrCliTextColors;
AfrCliTextColors::getInstance()->
bgBlueLight('Hello ')->
bgDefaultAllColorStyle( 'my ')->
styleBold(true)->
textAppend('bold ')->
colorGreen('World! ')->
styleBold(false)->
bgMagenta('How ')->
styleInvert(true)->
textAppend('Inverted ')->
styleInvert(false)->
bgCyanLight()->
colorYellowLight('is the ')->
styleItalic(true)->
colorRed('rainbow?')->
styleDefaultAllBgColor()->
textPrint();
```