⚠️ NO LONGER MAINTAINED This list is no longer kept up to date, so some of its information may no longer be relevant.
This is a list of tools, frameworks & examples that you might find useful when scripting in Swift 🚀
Marathon makes it easy to write, run and manage your Swift scripts. Quickly create, edit, run, install & share your scripts, and easily add dependencies to them.
PackageBuilder builds a simple command-line structure using SPM. The structure follows the approach described in Building a command line tool using the Swift Package Manager separating your code between a framework and the executable.
The Package Manager for the Swift Programming Language. Using it you can manage your dependencies + compile & run your scripts. Also enables you to generate Xcode projects for your scripts.
While most Swift frameworks can be used in scripts, the ones in this list are particularily useful in tasks that are common when doing Swift scripting.
Commandant is a Swift framework for parsing command-line arguments, inspired by Argo (which is, in turn, inspired by the Haskell library Aeson).
Commander is a small Swift framework allowing you to craft beautiful command line interfaces in a composable way. Accept input in a type safe way with great error handling and provide descriptions for your arguments.
A pure Swift library for creating command-line interfaces. Using it, you can easily accept parameters & flags in your scripts, and print help messages & usage instructions for them.
A nicer way to handle files & folders in Swift. Files gives you an object-oriented API around the file system, making it easy to create, move, rename and handle files & folders in a script.
Guaka helps you create modern and familiar CLI apps in the vein of widely used projects such as: Docker, Kubernetes, OpenShift, Hugo and more.
A Cross-Platform String and Regular Expression Library Written in Swift. Makes it easier to handle strings (such as input) in your scripts, evaluate regular expressions on them, transform them, and more.
Delightful console output for Swift developers. Rainbow makes it easy to color the text your script outputs on the command line.
A Swift package for resolving released versions from a Git repository. Enables you to easily build tooling around Git versions. Resolve, sort & filter versions for both remote & local repositories.
Easily run shell commands from a Swift script or command line tool. Gives you a simple function that enables you to "shell out" and run tasks on the command line from your scripts.
Swiftline is a set of tools to help you create command line applications.
A library for creating command-line applications and running shell commands in Swift. It provides features such as running asynchronous tasks, handling contexts & errors and managing input & output.
A Swift package for generating Xcode workspaces & playgrounds. Using it, you can build developer tools & scripts that generates workspaces for your projects, or playgrounds for quick prototyping.
Carting is a simple tool for updating Carthage Build Phase.
A collection of example Swift scripts that can easily be run using Marathon.
Instantly create Swift playgrounds from the command line.
A stupid simple Swift Web Crawler.
Quickly try out any Swift pod or framework in a playground.
This list is still in its early days, so a lot of awesome stuff is sure to be missing. If you know of a tool, framework or example that should be on this list - add it and open a PR! 👍 Before you do though, here are some quick guidelines:
Looking forward to your contributions and seeing this list grow! 🎉