https://github.com/milan-miscevic/folder
Folder scanner
https://github.com/milan-miscevic/folder
absolute-path active-folder files folder folders relative-path scanner
Last synced: 10 months ago
JSON representation
Folder scanner
- Host: GitHub
- URL: https://github.com/milan-miscevic/folder
- Owner: milan-miscevic
- License: mit
- Created: 2018-01-03T19:31:57.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-02-22T06:42:18.000Z (over 3 years ago)
- Last Synced: 2025-07-18T05:25:53.435Z (11 months ago)
- Topics: absolute-path, active-folder, files, folder, folders, relative-path, scanner
- Language: PHP
- Homepage:
- Size: 118 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# folder
[](LICENSE)
[](https://github.com/php-pds/skeleton)
[](https://github.com/milan-miscevic/folder/actions)
[](https://sonarcloud.io/dashboard?id=milan-miscevic_folder)
[](https://shepherd.dev/github/milan-miscevic/folder)
[](https://dashboard.stryker-mutator.io/reports/github.com/milan-miscevic/folder/master)
A folder scanner.
## Usage
```php
use Mmm\Folder\ActiveFolder;
use Mmm\Folder\ActiveSubFolder;
$af = new ActiveFolder(__DIR__);
$af->getFolders(); // returns a list of folders
$af->getAbsoluteFolders(); // returns a list of folders with absolute paths
$af->getFiles(); // returns a list of files
$af->getAbsoluteFiles(); // returns a list of files with absolute paths
$asf = new ActiveSubFolder(__DIR__, '.');
$asf->getFolders();
$asf->getAbsoluteFolders();
$asf->getRelativeFolders(); // returns a list of folders with relative paths to the base folder
$asf->getFiles();
$asf->getAbsoluteFiles();
$asf->getRelativeFiles(); // returns a list of files with relative paths to the base folder
```