Skip to content
This repository has been archived by the owner on Sep 6, 2018. It is now read-only.

Commit

Permalink
Use (default) stencil join
Browse files Browse the repository at this point in the history
  • Loading branch information
djbe committed May 16, 2017
2 parents 2fbb558 + 3c1a57d commit 65777fc
Show file tree
Hide file tree
Showing 12 changed files with 10 additions and 29 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Expand Up @@ -15,6 +15,9 @@
* Templates are now organized in subdirectories for each command.
[@djbe](https://github.com/djbe)
[#13](https://github.com/SwiftGen/templates/issues/13)
* Update templates to use the Stencil built-in `join` filter instead of our own.
[@djbe](https://github.com/djbe)
[#22](https://github.com/SwiftGen/templates/issues/22)

### New Features

Expand Down
2 changes: 1 addition & 1 deletion Podfile.lock
Expand Up @@ -15,7 +15,7 @@ EXTERNAL SOURCES:

CHECKOUT OPTIONS:
StencilSwiftKit:
:commit: cc2bf33b1e138c8ca068fa460c42a7979adf9947
:commit: 21da18cdefe2deda281c134173f7558b37536250
:git: https://github.com/SwiftGen/StencilSwiftKit

SPEC CHECKSUMS:
Expand Down
2 changes: 1 addition & 1 deletion Pods/Manifest.lock

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

1 change: 0 additions & 1 deletion Pods/StencilSwiftKit/README.md

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

1 change: 0 additions & 1 deletion Pods/StencilSwiftKit/Sources/Environment.swift

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

16 changes: 0 additions & 16 deletions Pods/StencilSwiftKit/Sources/Filters.swift

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

4 changes: 0 additions & 4 deletions Pods/StencilSwiftKit/Sources/Parameters.swift

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

2 changes: 1 addition & 1 deletion templates/strings/default.stencil
Expand Up @@ -7,7 +7,7 @@ import Foundation
{% macro recursiveBlock item %}
{% for string in item.strings %}
/// {{string.translation}}
case {{string.key|swiftIdentifier|snakeToCamelCase|escapeReservedKeywords}}{% if string.types %}({{string.types|join}}){% endif %}
case {{string.key|swiftIdentifier|snakeToCamelCase|escapeReservedKeywords}}{% if string.types %}({{string.types|join:", "}}){% endif %}
{% endfor %}
{% for child in item.children %}
{% call recursiveBlock child %}
Expand Down
2 changes: 1 addition & 1 deletion templates/strings/genstrings.stencil
Expand Up @@ -7,7 +7,7 @@ import Foundation
{% macro recursiveBlock item %}
{% for string in item.strings %}
/// {{string.translation}}
case {{string.key|swiftIdentifier|snakeToCamelCase|escapeReservedKeywords}}{% if string.types %}({{string.types|join}}){% endif %}
case {{string.key|swiftIdentifier|snakeToCamelCase|escapeReservedKeywords}}{% if string.types %}({{string.types|join:", "}}){% endif %}
{% endfor %}
{% for child in item.children %}
{% call recursiveBlock child %}
Expand Down
2 changes: 1 addition & 1 deletion templates/strings/no-comments-swift3.stencil
Expand Up @@ -6,7 +6,7 @@ import Foundation
// swiftlint:disable file_length
{% macro recursiveBlock item %}
{% for string in item.strings %}
case {{string.key|swiftIdentifier|snakeToCamelCase|lowerFirstWord|escapeReservedKeywords}}{% if string.types %}({{string.types|join}}){% endif %}
case {{string.key|swiftIdentifier|snakeToCamelCase|lowerFirstWord|escapeReservedKeywords}}{% if string.types %}({{string.types|join:", "}}){% endif %}
{% endfor %}
{% for child in item.children %}
{% call recursiveBlock child %}
Expand Down
2 changes: 1 addition & 1 deletion templates/strings/structured.stencil
Expand Up @@ -11,7 +11,7 @@ enum {{enumName}} {
{% macro enumBlock item sp %}
{{sp}} {% for string in item.strings %}
{{sp}} /// {{string.translation}}
{{sp}} case {{string.name|swiftIdentifier|snakeToCamelCase|escapeReservedKeywords}}{% if string.types %}({{string.types|join}}){% endif %}
{{sp}} case {{string.name|swiftIdentifier|snakeToCamelCase|escapeReservedKeywords}}{% if string.types %}({{string.types|join:", "}}){% endif %}
{{sp}} {% endfor %}
{{sp}} {% for child in item.children %}

Expand Down
2 changes: 1 addition & 1 deletion templates/strings/swift3.stencil
Expand Up @@ -7,7 +7,7 @@ import Foundation
{% macro recursiveBlock item %}
{% for string in item.strings %}
/// {{string.translation}}
case {{string.key|swiftIdentifier|snakeToCamelCase|lowerFirstWord|escapeReservedKeywords}}{% if string.types %}({{string.types|join}}){% endif %}
case {{string.key|swiftIdentifier|snakeToCamelCase|lowerFirstWord|escapeReservedKeywords}}{% if string.types %}({{string.types|join:", "}}){% endif %}
{% endfor %}
{% for child in item.children %}
{% call recursiveBlock child %}
Expand Down

0 comments on commit 65777fc

Please sign in to comment.