Skip to content

Commit

Permalink
Rename the Pod SwiftGenKit -> GenumKit
Browse files Browse the repository at this point in the history
  • Loading branch information
AliSoftware committed Oct 14, 2015
1 parent 420ddc0 commit 12aeed7
Show file tree
Hide file tree
Showing 41 changed files with 357 additions and 375 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
//
// GenumKit
// Copyright (c) 2015 Olivier Halligon
// MIT Licence
//

import Foundation

public enum SwiftGenIndentation {
public enum Indentation {
case Tab
case Spaces(Int)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
//
// GenumKit
// Copyright (c) 2015 Olivier Halligon
// MIT Licence
//

import Foundation

extension String {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
//
// GenumKit
// Copyright (c) 2015 Olivier Halligon
// MIT Licence
//

import Foundation
//@import SwiftIdentifier
//@import SwiftGenIndentation

public final class AssetsEnumBuilder {
private var assetNames = [String]()
Expand Down Expand Up @@ -28,7 +32,7 @@ public final class AssetsEnumBuilder {
}
}

public func build(enumName enumName : String = "Asset", indentation indent : SwiftGenIndentation = .Spaces(4)) -> String {
public func build(enumName enumName : String = "Asset", indentation indent : Indentation = .Spaces(4)) -> String {
var text = "// Generated using SwiftGen, by O.Halligon — https://github.com/AliSoftware/SwiftGen\n\n"
let t = indent.string

Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
//
// GenumKit
// Copyright (c) 2015 Olivier Halligon
// MIT Licence
//

import Foundation
//@import SwiftIdentifier
//@import SwiftGenIndentation

public final class SwiftGenColorEnumBuilder {
public final class ColorEnumBuilder {
public init() {}

public func addColorWithName(name: String, value: String) {
addColorWithName(name, value: SwiftGenColorEnumBuilder.parse(value))
addColorWithName(name, value: ColorEnumBuilder.parse(value))
}

public func addColorWithName(name: String, value: UInt32) {
Expand Down Expand Up @@ -35,7 +39,7 @@ public final class SwiftGenColorEnumBuilder {
}
}

public func build(enumName enumName: String = "Name", generateStringInit stringInit: Bool = false, indentation indent: SwiftGenIndentation = .Spaces(4)) -> String {
public func build(enumName enumName: String = "Name", generateStringInit stringInit: Bool = false, indentation indent: Indentation = .Spaces(4)) -> String {
var text = "// Generated using SwiftGen, by O.Halligon — https://github.com/AliSoftware/SwiftGen\n\n"
let t = indent.string
text += commonCode(generateStringInit: stringInit, indentationString: t)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
//
// GenumKit
// Copyright (c) 2015 Olivier Halligon
// MIT Licence
//

import Foundation
//@import SwiftIdentifier
//@import SwiftGenIndentation

public final class L10nEnumBuilder {
public init() {}
Expand All @@ -19,7 +23,7 @@ public final class L10nEnumBuilder {
}
}

public func build(enumName enumName : String = "L10n", indentation indent : SwiftGenIndentation = .Spaces(4)) -> String {
public func build(enumName enumName : String = "L10n", indentation indent : Indentation = .Spaces(4)) -> String {
var text = "// Generated using SwiftGen, by O.Halligon — https://github.com/AliSoftware/SwiftGen\n\n"
text += "import Foundation\n\n"

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
//
// GenumKit
// Copyright (c) 2015 Olivier Halligon
// MIT Licence
//

import Foundation
//@import SwiftIdentifier
//@import SwiftGenIndentation

public final class StoryboardEnumBuilder {
private typealias Scene = (storyboardID: String, customClass: String?)
Expand Down Expand Up @@ -84,7 +88,7 @@ public final class StoryboardEnumBuilder {
}
}

public func build(scenesStructName scenesStructName: String = "Scene", seguesStructName: String = "Segue", indentation indent : SwiftGenIndentation = .Spaces(4)) -> String {
public func build(scenesStructName scenesStructName: String = "Scene", seguesStructName: String = "Segue", indentation indent : Indentation = .Spaces(4)) -> String {
var text = "// Generated using SwiftGen, by O.Halligon — https://github.com/AliSoftware/SwiftGen\n\n"
let t = indent.string
text += commonCode(indentationString: t)
Expand Down
6 changes: 4 additions & 2 deletions SwiftGenKit/SwiftGenKit.podspec → GenumKit/GenumKit.podspec
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
Pod::Spec.new do |s|

s.name = "SwiftGenKit"
s.name = "GenumKit"
s.version = "0.5.0"
s.summary = "A tool to build constants using enums for your UIImage, Storyboards, Assets, Colors, and more"

s.description = <<-DESC
SwiftGen is a framework and command-line tool to build constants using enums for:
GenumKit is a framework to build constants using enums for:
- UIImages from your Assets Catalogs
- Storyboards, to instanciate scenes and identify segues using constants
- UIColors, to have named colors using an enums
- Localizable.strings so that you can format your localized text way easier!
This framework is used by the swiftgen Command Line tool
DESC

s.homepage = "https://github.com/AliSoftware/SwiftGen"
Expand Down
4 changes: 2 additions & 2 deletions Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ use_frameworks!

target 'swiftgen' do
pod 'Commander'
pod 'SwiftGenKit', :path => 'SwiftGenKit'
pod 'GenumKit', :path => 'GenumKit'
end

target 'UnitTests' do
pod 'SwiftGenKit', :path => 'SwiftGenKit'
pod 'GenumKit', :path => 'GenumKit'
end
10 changes: 5 additions & 5 deletions Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
PODS:
- Commander (0.2.2)
- SwiftGenKit (0.5.0)
- GenumKit (0.5.0)

DEPENDENCIES:
- Commander
- SwiftGenKit (from `SwiftGenKit`)
- GenumKit (from `GenumKit`)

EXTERNAL SOURCES:
SwiftGenKit:
:path: SwiftGenKit
GenumKit:
:path: GenumKit

SPEC CHECKSUMS:
Commander: 3634740c4e1ed3a76ff55426424950e4c8a822e0
SwiftGenKit: e9aa540b7b5a798372882404f598bc8974ed438b
GenumKit: 50007ccd336c3887a503527d4facd07b6183bc62

COCOAPODS: 0.39.0

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions Pods/Manifest.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 12aeed7

Please sign in to comment.