Download the PHP package phpfiletool/filetool without Composer

On this page you can find all versions of the php package phpfiletool/filetool. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package filetool

PHP FileTool

PHP Version Packagist Version GitHub Actions Workflow Status GitHub Release License

PHP FileTool is a simple PHP library for working with files and directories.

It provides useful methods to create, read, write, copy, rename, list and delete files or directories using a clean static API.


Features


Requirements


Installation

Install the package with Composer:


Basic Usage


File Operations

Create a file

You can also pass the file extension separately:


Create multiple files

This creates files like:


Write to a file

The third argument controls overwrite mode:


Read a file


Copy a file

If the destination file already exists, PHP FileTool creates a unique name automatically:


Copy file content


Rename a file or path


Delete a file


Directory Operations

Create a directory

You can also define permissions:


List files in a directory


Copy all files from one directory to another


Delete all files from a directory

This removes files inside the directory, but keeps the directory itself.


Delete an empty directory


Delete a directory recursively

Be careful: this removes the directory and its contents recursively.


Exception Handling

PHP FileTool uses custom exceptions so you can handle errors more safely.

Available exceptions:


Facade Methods

The main facade is:

Main methods:


Legacy Method Aliases

For compatibility, some old method names are still available:

Prefer the new descriptive method names in new projects.


Development

Install dependencies:

Run tests:

Run PHPStan:

Run PHPCS:

Fix coding style automatically when possible:


Quality Tools

This project uses:


Changelog

See CHANGELOG.md for version history.


Contributing

Contributions are welcome.

Before opening a pull request, run:


Author

Antonio Silva


License

This project is licensed under the GPL-3.0-or-later license.

See the LICENSE file for more details.


All versions of filetool with dependencies

PHP Build Version
Package Version
Requires php Version ^8.4
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package phpfiletool/filetool contains the following files

Loading the files please wait ...