Sha256: 52030e3471d6e9d8e15dd64b05aebc531d509314147a48b5300e5839b9995d40

Contents?: true

Size: 944 Bytes

Versions: 15

Compression:

Stored size: 944 Bytes

Contents

// RubyCommandable.swift
// Copyright (c) 2020 FastlaneTools

//
//  ** NOTE **
//  This file is provided by fastlane and WILL be overwritten in future updates
//  If you want to add extra functionality to this project, create a new file in a
//  new group so that it won't be marked for upgrade
//

import Foundation

enum CommandType {
    case action
    case control

    var token: String {
        switch self {
        case .action:
            return "action"
        case .control:
            return "control"
        }
    }
}

protocol RubyCommandable {
    var type: CommandType { get }
    var commandJson: String { get }
    var id: String { get }
}

extension RubyCommandable {
    var json: String {
        return """
        { "commandType": "\(type.token)", "command": \(commandJson) }
        """
    }
}

// Please don't remove the lines below
// They are used to detect outdated files
// FastlaneRunnerAPIVersion [0.9.2]

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
fastlane-2.173.0 fastlane/swift/RubyCommandable.swift
fastlane-2.172.0 fastlane/swift/RubyCommandable.swift
fastlane-2.171.0 fastlane/swift/RubyCommandable.swift
fastlane-2.170.0 fastlane/swift/RubyCommandable.swift
fastlane-2.169.0 fastlane/swift/RubyCommandable.swift
fastlane-2.168.0 fastlane/swift/RubyCommandable.swift
fastlane-2.167.0 fastlane/swift/RubyCommandable.swift
fastlane-2.166.0 fastlane/swift/RubyCommandable.swift
fastlane-2.165.0 fastlane/swift/RubyCommandable.swift
fastlane-2.164.0 fastlane/swift/RubyCommandable.swift
fastlane-2.163.0 fastlane/swift/RubyCommandable.swift
fastlane-2.162.0 fastlane/swift/RubyCommandable.swift
fastlane-2.161.0 fastlane/swift/RubyCommandable.swift
fastlane-2.160.0 fastlane/swift/RubyCommandable.swift
fastlane-2.159.0 fastlane/swift/RubyCommandable.swift