Skip to content

taphouseio/tuist-module-plugin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tuist Module Plugin

This repo serves as a plugin to the excellent Tuist Xcode project generator. The plugin adds functionality to easily create a module structure for your repository. Check out the Runway blog post for an introduction to Tuist an the structure of modules.

Getting Started

Using this plugin from Tuist is straightforward. In your Config.swift file add this entry:

let config = Config(
    plugins: [
        .git(url: "https://github.com/runway-org/tuist-module-plugin", tag: "1.0.0")
    ]
)

Inside of your ProjectDescriptionHelpers you can declare modules like this:

import Foundation
import ProjectDescription
import ModuleDescription

extension Module {
    public static var sampleApp: Module {
        .init(name: .sampleApp, config: appConfig)
    }
}

extension ModuleName {
    public static var sampleApp: ModuleName = "App"
}

private let appConfig = Module.Config(
    dependencies: [
        // Your other modules
    ],
    product: .custom(.app),
    testConfig: Module.TestConfig(hasResources: false)
)

From there the Project.swift becomes much simpler:

import ProjectDescription
import ProjectDescriptionHelpers
import ModuleDescription

let project = Project(
    bundleID: bundleBaseID,
    modules: [
        .sampleApp,
        // Your other modules
    ]
)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages