okapi/path
最新稳定版本:1.0.0
Composer 安装命令:
composer require okapi/path
包简介
PHP Path is a PHP library that provides utilities for handling file paths.
关键字:
README 文档
README
PHP Path
PHP Path is a PHP library that provides utilities for handling file paths.
It is based on Node.js's path module.
Installation
composer require okapi/path
Usage
<?php use Okapi\Path\Path; // Resolve $path = Path::resolve('./path/to/file.txt'); // --> /project/path/to/file.txt $path = Path::resolve([ './path/to/file.txt', '../project2/file.txt', ]); // [0] --> /project/path/to/file.txt // [1] --> /project2/file.txt // Join $path = Path::join('/project', 'path', 'to', 'file.txt'); // --> /project/path/to/file.txt
Testing
- Run
composer run-script test
or - Run
composer run-script test-coverage
Show your support
Give a ⭐ if this project helped you!
📝 License
Copyright © 2023 Valentin Wotschel.
This project is MIT licensed.
统计信息
- 总下载量: 9.96k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 4
- 点击次数: 1
- 依赖项目数: 2
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2023-02-17