Skip to content

Latest commit

 

History

History
20 lines (15 loc) · 804 Bytes

README.md

File metadata and controls

20 lines (15 loc) · 804 Bytes

“Files”

Welcome to Files, a compact library that provides a nicer way to handle files and folders in Swift. It’s primarily aimed at Swift scripting and tooling, but can also be embedded in applications that need to access the file system. It's essentially a thin wrapper around the FileManager APIs that Foundation provides.

Features

  • Modern, object-oriented API for accessing, reading and writing files & folders.
  • Unified, simple do, try, catch error handling.
  • Easily construct recursive and flat sequences of files and folders.

Examples

Easily iterate over the files contained in a folder

for file in try Folder(path: "MyFolder") {
    print(file.name)
}