https://github.com/ixnode/php-size-byte
PHP Size Byte
https://github.com/ixnode/php-size-byte
Last synced: 6 months ago
JSON representation
PHP Size Byte
- Host: GitHub
- URL: https://github.com/ixnode/php-size-byte
- Owner: ixnode
- License: mit
- Created: 2022-12-18T23:18:49.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2022-12-19T09:57:59.000Z (almost 3 years ago)
- Last Synced: 2025-05-16T23:11:39.668Z (7 months ago)
- Language: Shell
- Size: 30.3 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# PHP Size Byte
This library converts given size into human-readable size.
## Installation
```bash
composer require ixnode/php-size-byte
```
```bash
vendor/bin/php-size-byte -V
```
```bash
php-size-byte 0.1.0 (12-19-2022 01:17:26) - Björn Hempel
```
## Usage
```php
use Ixnode\PhpSizeByte\SizeByte;
```
```php
$sizeHumanReadable = (new SizeByte($fileSize))->getHumanReadable();
```
## Development
```bash
git clone git@github.com:ixnode/php-size-byte.git && cd php-size-byte
```
```bash
composer install
```
```bash
composer test
```
## License
This tool is licensed under the MIT License - see the [LICENSE](/LICENSE) file for details