codesinging/filesystem

PHP 开发文件系统包

1.0.0 2019-12-04 09:00 UTC

This package is auto-updated.

Last update: 2024-09-04 20:09:10 UTC


README

PHP 开发文件系统包。

安装

$ composer require codesinging/filesystem -vvv

使用

文件系统

  • exists(string $path)
  • missing(string $path)
  • isFile(string $path)
  • isDirectory(string $directory)
  • isReadable(string $path)
  • isWritable(string $path)
  • get(string $path)
  • put(string $path, string $contents, int $flags = 0)
  • chmod(string $path, int $mode = null)
  • prepend(string $path, string $content)
  • append(string $path, string $content)
  • delete($paths)
  • move(string $path, string $target)
  • copy(string $path, string $target)
  • name(string $path)
  • basename(string $path)
  • dirname(string $path)
  • extension(string $path)
  • type(string $path)
  • mimeType(string $path)
  • size(string $path)
  • lastModified(string $path)
  • hash(string $path)
  • replace(string $path, string $content)
  • glob(string $pattern, int $flags = 0)
  • files(string $directory, bool $recursive = false, bool $hidden = false)
  • allFiles(string $directory, bool $hidden = false)
  • directories(string $directory)
  • makeDirectory(string $path, int $mode = 0755, bool $recursive = false, bool $force = false)
  • moveDirectory($from, $to, $overwrite = false)
  • copyDirectory(string $directory, string $destination, int $options = null)
  • deleteDirectory(string $directory, bool $preserve = false)
  • cleanDirectory(string $directory)

贡献

您可以通过以下三种方式之一进行贡献

  1. 使用 问题跟踪器 提交错误报告。
  2. 问题跟踪器 上回答问题或修复错误。
  3. 贡献新功能或更新维基百科。

代码贡献过程并不非常正式。您只需确保遵循 PSR-0、PSR-1 和 PSR-2 编码指南。任何新的代码贡献都必须伴随单元测试(如果适用)。

许可

MIT