Swiftpack.co - Package - tuist/tuist

code style: prettier CircleCI codecov Slack

What's Tuist 🕺

Tuist is a command line tool that helps you generate, maintain and interact with Xcode projects.

It's open source and written in Swift.

Defining your projects 💼

With Tuist, projects are defined in a Project.swift, also known as manifest. The manifest format abstracts you from the implementation details of Xcode projects. In your manifest you can define which targets your project has, which sources and resources belong to them, as well as the dependencies with targets in the same and other projects. The advantages of defining the projects in a manifest are:

  • It can catch misconfigurations and fail early. For example, if a target has an invalid dependency, it’ll let you know before you start compiling the app.
  • Since the manifest doesn’t include Xcode implementation details, the likelihood of having git conflicts is significantly lower.
  • It makes the configuration easier. The decision on how the project looks is on you. Tuist processes it and manages the complexity for you. One example of that complexity is setting up dependencies between targets.

The example below shows how projects are defined with Tuist:

import ProjectDescription

let project = Project(name: "App",
                      targets: [
                        Target(name: "App",
                               platform: .iOS,
                               product: .app,
                               bundleId: "io.tuist.App",
                               infoPlist: "Info.plist",
                               sources: ["Sources/**", "OtherSources/**"],
                               dependencies: [
                                    /* Target dependencies can be defined here */
                                    /* .framework(path: "framework") */
                                ]),
                        Target(name: "AppTests",
                               platform: .iOS,
                               product: .unitTests,
                               bundleId: "io.tuist.AppTests",
                               infoPlist: "Tests.plist",
                               sources: "Tests/**",
                               dependencies: [
                                    .target(name: "App")
                               ])
                      ])

Interacting with your projects 🙇‍♀️

Tuist leverages project generation to provide a simple and convenient set of commands, standard across all the projects. The commands infer most of the necessary information from your projects, requiring you to pass only the arguments that are strictly necessary.

Having a standard command line interface makes it easier to jump between projects since there’s an interaction language everyone in the team is familiar with.

  • 👩‍💻 Init: Bootstraps a new project. You can specify the platform and the type of project and it’ll generate all the necessary artifacts (Info.plist, AppDelegate, Project.swift, Playgrounds…).
  • 💫 Generate: Generates the Xcode workspace and projects to work on a particular project.
  • 📦 Build: (Not available yet) Builds the project in the current directory. It supports all the arguments that xcodebuild supports.
  • ✅ Test: (Not available yet) Test the project in the current directory. It supports all the arguments that xcodebuild supports.
  • 📱 Run: (Not available yet) Runs the project. If the project needs a device to run on, it’ll prompt you to select one.
  • 🚀 Release: (Not available yet) Builds and publishes your project on iTunes Connect.

The list of actions will likely grow as we get feedback from you.

Install ⬇️

Running script (Recommended)

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/tuist/tuist/master/install/install)"

Bootstrap your first project 🌀

tuist init --platform ios --product application
tuist generate # Generates Xcode project

Check out the project "Getting Started" guide to learn more about Tuist and all its features.

Documentation 📝

Do you want to know more about what Tuist can offer you? Or perhaps want to contribute to the project and you need a starting point? You can check out the project documentation.

Setup for development 👩‍💻

  1. Git clone: git clone git@github.com:tuist/tuist.git
  2. Generate Xcode project with swift package generate-xcodeproj.
  3. Open tuist.xcodeproj.
  4. Have fun 🤖

Testing

Unit tests

Tuist has a suite of unit tests for its various target that can be run via Swift Packager Manager by invoking:

swift test

Acceptance tests

Additionally, Tuist has a few high level acceptance tests written in cucumber and ruby which can be run by invoking:

rake features

Shield

If your project uses Tuist, you can add the following badge to your project README:

Tuist Badge

[![Tuist Badge](https://img.shields.io/badge/powered%20by-Tuist-green.svg?longCache=true)](https://github.com/tuist)

Open source

Tuist is a proud supporter of the Software Freedom Conservacy

Become a Conservancy Supporter!

License

FOSSA Status

Github

link
Stars: 636
Help us keep the lights on

Dependencies

Releases

0.16.0 - Jun 21, 2019

Added

  • DefaultSettings.none to disable the generation of default build settings https://github.com/tuist/tuist/pull/395 by @pepibumur.
  • Version information for tuistenv https://github.com/tuist/tuist/pull/399 by @ollieatkinson
  • Add input & output paths for target action https://github.com/tuist/tuist/pull/353 by Rag0n
  • Adding support for linking system libraries and frameworks https://github.com/tuist/tuist/pull/353 by @steprescott

Fixed

  • Ensuring the correct default settings provider dependency is used https://github.com/tuist/tuist/pull/389 by @kwridan
  • Fixing build settings repeated same value https://github.com/tuist/tuist/pull/391 by @platonsi
  • Duplicated files in the sources build phase when different glob patterns match the same files https://github.com/tuist/tuist/pull/388 by @pepibumur.
  • Support .d source files https://github.com/tuist/tuist/pull/396 by @pepibumur.
  • Codesign frameworks when copying during the embed phase https://github.com/tuist/tuist/pull/398 by @ollieatkinson
  • 'tuist local' failed when trying to install from source https://github.com/tuist/tuist/pull/402 by @ollieatkinson
  • Omitting unzip logs during installation https://github.com/tuist/tuist/pull/404 by @kwridan
  • Fix "The file couldn’t be saved." error https://github.com/tuist/tuist/pull/408 by @marciniwanicki
  • Ensure generated projects are stable https://github.com/tuist/tuist/pull/410 by @kwridan
  • Stop generating empty PBXBuildFile settings https://github.com/tuist/tuist/pull/415 by @marciniwanicki

0.15.0 - Jun 2, 2019

Changed

  • Introduce the InfoPlist file https://github.com/tuist/tuist/pull/373 by @pepibumur.
  • Add defaultSettings option to Settings definition to control default settings generation https://github.com/tuist/tuist/pull/378 by @marciniwanicki

Added

  • Adding generate command timer https://github.com/tuist/tuist/pull/335 by @kwridan
  • Support Scheme manifest with pre/post action https://github.com/tuist/tuist/pull/336 by @dangthaison91
  • Support local Scheme (not shared) flag https://github.com/tuist/tuist/pull/341 by @dangthaison91
  • Support for compiler flags https://github.com/tuist/tuist/pull/386 by @pepibumur.

Fixed

  • Fixing unstable diff (products and embedded frameworks) https://github.com/tuist/tuist/pull/357 by @marciniwanicki
  • Set Code Sign On Copy to true for Embed Frameworks https://github.com/tuist/tuist/pull/333 by @dangthaison91
  • Fixing files getting mistaken for folders https://github.com/tuist/tuist/pull/338 by @kwridan
  • Updating init template to avoid warnings https://github.com/tuist/tuist/pull/339 by @kwridan
  • Fixing generation failures due to asset catalog & **/*.png glob patterns handling https://github.com/tuist/tuist/pull/346 by @kwridan
  • Supporting bundle target dependencies that reside in different projects (in TuistGenerator) https://github.com/tuist/tuist/pull/348 by @kwridan
  • Fixing header paths including folders and non-header files https://github.com/tuist/tuist/pull/356 by @kwridan
  • Fix duplicate localized resource files https://github.com/tuist/tuist/pull/363 by @kwridan
  • Update static dependency lint rule https://github.com/tuist/tuist/pull/360 by @kwridan
  • Ensure resource bundles in other projects get built https://github.com/tuist/tuist/pull/374 by @kwridan

0.14.0 - Apr 28, 2019

Added

  • Adding support for project additional files https://github.com/tuist/tuist/pull/314 by @kwridan
  • Adding support for resource folder references https://github.com/tuist/tuist/pull/318 by @kwridan
  • Breaking Swift 5 support https://github.com/tuist/tuist/pull/317 by @pepibumur.

Fixed

  • Ensuring target product names are consistent with Xcode https://github.com/tuist/tuist/pull/323 by @kwridan
  • Ensuring generate works on additional disk volumes https://github.com/tuist/tuist/pull/327 by @kwridan
  • Headers build phase should be put on top of Compile build phase https://github.com/tuist/tuist/pull/332 by @dangthaison91

0.13.0 - Mar 30, 2019

Added

  • Add Homebrew tap up https://github.com/tuist/tuist/pull/281 by @pepibumur
  • Create a Setup.swift file when running the init command https://github.com/tuist/tuist/pull/283 by @pepibumur
  • Update tuistenv when running tuist update https://github.com/tuist/tuist/pull/288 by @pepibumur.
  • Allow linking of static products into dynamic frameworks https://github.com/tuist/tuist/pull/299 by @ollieatkinson
  • Workspace improvements https://github.com/tuist/tuist/pull/298 by @ollieatkinson & @kwridan.

Removed

  • Breaking Removed "-Project" shared scheme from being generated https://github.com/tuist/tuist/pull/303 by @ollieatkinson

Fixed

  • Fix duplicated embedded frameworks https://github.com/tuist/tuist/pull/280 by @pepibumur
  • Fix manifest target linker errors https://github.com/tuist/tuist/pull/287 by @kwridan
  • Build settings not being generated properly https://github.com/tuist/tuist/pull/282 by @pepibumur
  • Fix instance method nearly matches optional requirements warning in generated AppDelegate.swift in iOS projects https://github.com/tuist/tuist/pull/291 by @BalestraPatrick
  • Fix Header & Framework search paths override project or xcconfig settings https://github.com/tuist/tuist/pull/301 by @ollieatkinson
  • Unit tests bundle for an app target compile & run https://github.com/tuist/tuist/pull/300 by @ollieatkinson
  • LIBRARY_SEARCH_PATHS and SWIFT_INCLUDE_PATHS are now set https://github.com/tuist/tuist/pull/308 by @kwridan
  • Fix Generation fails in the event an empty .xcworkspace directory exists https://github.com/tuist/tuist/pull/312 by @ollieatkinson

0.12.0 - Mar 11, 2019

Changed

  • Rename manifest group to Manifest https://github.com/tuist/tuist/pull/227 by @pepibumur.
  • Rename manifest target to Project-Manifest https://github.com/tuist/tuist/pull/227 by @pepibumur.
  • Replace swiftlint with swiftformat https://github.com/tuist/tuist/pull/239 by @pepibumur.
  • Bump xcodeproj version to 6.6.0 https://github.com/tuist/tuist/pull/248 by @pepibumur.
  • Fix an issue with Xcode not being able to reload the projects when they are open https://github.com/tuist/tuist/pull/247
  • Support array for sources and resources paths https://github.com/tuist/tuist/pull/201 by @dangthaison91

Added

  • Integration tests for generate command https://github.com/tuist/tuist/pull/208 by @marciniwanicki & @kwridan
  • Frequently asked questions to the documentation https://github.com/tuist/tuist/pull/223/ by @pepibumur.
  • Generate a scheme with all the project targets https://github.com/tuist/tuist/pull/226 by @pepibumur
  • Documentation for contributors https://github.com/tuist/tuist/pull/229 by @pepibumur
  • Support for Static Frameworks https://github.com/tuist/tuist/pull/194 @ollieatkinson

Removed

  • Up attribute from the Project model https://github.com/tuist/tuist/pull/228 by @pepibumur.
  • Support for YAML and JSON formats as Project specifications https://github.com/tuist/tuist/pull/230 by @ollieatkinson

Fixed

  • Changed default value of SWIFT_VERSION to 4.2 @ollieatkinson
  • Added fixture tests for ios app with static libraries @ollieatkinson
  • Bundle id linting failing when the bundle id contains variables https://github.com/tuist/tuist/pull/252 by @pepibumur
  • Include linked library and embed in any top level executable bundle https://github.com/tuist/tuist/pull/259 by @ollieatkinson