StencilSwiftKit CHANGELOG
August 3, 2022 · View on GitHub
Stable Branch
Breaking Changes
None
New Features
None
Bug Fixes
None
Internal Changes
None
2.10.1
Internal Changes
- Pin
Komondorto 1.1.3, to avoid issues with SPM for other packages depending on this package.
redryerye #162
2.10.0
Breaking Changes
- With the Stencil update, we're deprecating our
StencilSwiftTemplatetemplate class which contained a workaround that's no longer needed. It will also no longer be set by default by thestencilSwiftEnvironmentbuilder.
David Jennes #159 - With the Stencil update, we're deprecating our
removeNewlinesfilter, as this can now be achieved by the built-in Stencil syntax.
David Jennes #159
New Features
- Updated to Stencil 0.15.0, which contains many improvements, chief amongst them is whitespace behaviour control.
David Jennes #159 - Added an
importtag for reusing macro's in multiple templates from a common imported file.
David Jennes #111 - The
swiftIdentifiernow supports avalidmode, where it will do the bare minimum to get a valid identifier. I.e. it will not change the case of characters at all (compared tonormalmode).
David Jennes #160
Internal Changes
- Add
Dangerto check pull requests.
David Jennes #158
2.9.0
New Features
stencilSwiftEnvironmentnow accepts a list of paths (for the template loader) & extensions.
David Jennes #154 #156- The string filter
replacecan now accept an optional parameterregexto enable regular expressions, see the documentation for more information.
David Jennes JanGorman #123 #155
Internal Changes
- Update to SwiftLint 0.47.1 and enable some extra SwiftLint rules.
David Jennes #140 #153
2.8.0
New Features
- Added support for Swift 5.
David Jennes @fortmarek #119 #122 #125 #127 - Updated Stencil to the latest version (0.14).
@fortmarek #127
Bug Fixes
- Fix crash with the
lowerFirstWordfilter when running on empty strings.
@fortmarek #127
Internal Changes
- Update to SwiftLint 0.42.0 and enable some extra SwiftLint rules.
David Jennes @fortmarek #116 #127 #137 - Switch from CircleCI to GitHub Actions.
David Jennes #128 - Dropped support for Swift 4.2.
David Jennes #132 - Switched the whole project over to use Swift Package Manager, restructuring some of the internals in the process.
David Jennes #130 - Made the filter implementations public, so they can be used in other libraries.
David Jennes #136
2.7.2
Bug Fixes
Parameters: ensure theflattenfunction correctly handles a flag with afalsevalue.
David Jennes #108
Internal Changes
- Update to SwiftLint 0.30.1 and enable some extra SwiftLint rules.
David Jennes #112 #114
2.7.1
Bug Fixes
swiftIdentifier: fix crash on empty string.
David Jennes #105
2.7.0
New Features
- Updated Stencil to the latest version (0.13).
David Jennes #103
Internal Changes
- Improved the documentation of string filters a bit for a better overview of the inputs & outputs.
David Jennes #102 - Updated to latest Xcode (10.0).
David Jennes #103
2.6.0
New Features
- The
settag can now directly accept an expression as value, see the documentation for an explanation on how this differs with the normalset/endsetpair.
David Jennes #87 - Updated Stencil to the latest version (0.12.1).
David Jennes #95 #99
Bug fixes
- Fixed using filter expression in call node.
Ilya Puchka #85 - Fixed compilation issue with Xcode 10 & Swift 4.2 by adding hints to help the compiler.
Olivier Halligon #93 - Migrated to PathKit for url filters. The dirname will return '.' for a filename without base directory.
Rahul Katariya Philip Jander #94
Internal Changes
- Updated to latest Xcode (9.3.0).
David Jennes #86 - Update to SwiftLint 0.27 and enable some extra SwiftLint rules.
David Jennes #96 - Test Linux SPM support in CI.
David Jennes #90
2.5.0
New Features
- Updated Stencil to the latest version (0.11.0).
David Jennes #83
Internal Changes
- Switched to using SwiftLint via CocoaPods instead of our own install scripts.
David Jennes #78 - Enabled some extra SwiftLint rules for better code consistency.
David Jennes #79 - Migrated to CircleCI 2.0.
David Jennes #81 - Migrated to Swift 4, and dropped support for Swift 3.
David Jennes #80
2.4.0
New Features
- Add
!counterpart for strings boolean filters.
Antondomashnev #68 - Updated Stencil to the latest version (0.10.1).
Ilya Puchka #73
2.3.0
New Features
- Added
Parameters.flatten(dictionary:)method to do the opposite ofParameters.parse(items:)and turn a dictionary into the list of parameters to pass from the command line.
Olivier Halligon #70
Bug Fixes
- Workaround for
parseStringto supportNSString.
Antondomashnev #68
2.2.0
New Features
- Accept
LosslessStringConvertibleinput for strings filters.
Antondomashnev #65 StencilContext.enrichnow also accept a Dictionary for specifying parameters (in preparation for supporting Config files in SwiftGen).
Olivier Halligon #66
Internal Changes
- Refactoring of
Filters+Strings.
Antondomashnev #63
2.1.0
New Features
- Added the
basenameanddirnamestring filters for getting a filename, or parent folder (respectively), out of a path.
David Jennes #60 - Modify the
swiftIdentifierstring filter to accept an optional "pretty" mode, to also apply thesnakeToCamelCasefilter and other manipulations if needed for a "prettier" but still valid identifier.
David Jennes #61
Internal Changes
- Ensure
swiftlintis run usingbundler.
David Jennes #59
2.0.1
2.0.0
Due to the removal of legacy code, there are a few breaking changes in this new version that affect both template writers as well as developers. We've provided a migration guide to help you through these changes, which you can find here: Migration Guide for 2.0
Breaking Changes
- The
ParametersErrorenum has been replaced by theParameters.Errornested type.
Olivier Halligon #37 - The
FilterErrorenum has been replaced by theFilters.Errornested type.
Olivier Halligon #37 - The filters in
StringFiltersandNumFiltersare now located underFilters.StringsandFilters.Numbers.
Olivier Halligon #40 - Removed the
joinfilter, as it's now integrated inStencilproper.
David Jennes #10 - Refactored the
snakeToCamelCasefilter to now accept an (optional) boolean parameter to control thenoPrefixbehaviour.
David Jennes #41 - Rename the
stringToSwiftIdentifierfunction toswiftIdentifierto better match the other method names.
David Jennes #46
New Features
- Added the
contains,replace,hasPrefix,hasSuffix,lowerFirstLetterfilters for strings.
Antondomashnev #54 - Added the
removeNewlinesfilter to remove newlines (and spaces) from a string.
David Jennes #47 #48
Bug Fixes
- Fix
snakeToCamelCaseparameters information in README.
Liquidsoul #45
1.0.2
New Features
- Added camelToSnakeCase filter.
Gyuri Grell #24
Bug Fixes
- The context enrich function won't overwrite existing values in the
envandparamvariables.
David Jennes #29
Internal Changes
- Further refactor the Rakefile into rakelibs, and add a Gemfile for gem dependencies.
David Jennes #28 #31 - Update Stencil to 0.9.0 and update project to Xcode 8.3.
Diogo Tridapalli #32 - Added documentation for tags and filters.
David Jennes #12
Deprecations
- The
ParametersErrorenum has been replaced by theParameters.Errornested type.ParametersErrorstill works (it is nowtypealias) but will be removed in the next major release.
Olivier Halligon - The
FilterErrorenum has been replaced by theFilters.Errornested type.FilterErrorstill works (it is nowtypealias) but will be removed in the next major release.
Olivier Halligon
1.0.1
Internal Changes
- Switch from Travis CI to Circle CI, clean up the Rakefile in the process.
David Jennes #20 #25 - Fixed SPM dependency in
Package.swift.
Krzysztof Zabłocki #26
1.0.0
New Features
- Added support for Swift Package Manager.
Krzysztof Zabłocki #15 - Added
MapNodeto apply amapoperator to an array. You can now use{% map someArray into result using item %}to do the equivalent of theresult = someArray.map { item in … }Swift code.
David Jennes #11 - Add a "parameters parser" able to transform parameters passed as a set of strings
(
a=1 b.x=2 b.y=3 c=4 c=5) — typically provided as the command line arguments of a CLI — into a Dictionary suitable for Stencil contexts.
David Jennes #8 - Add a
StencilContext.enrichfunction to enrich Stencil contexts withparamandenvdictionaries.
Theparamdictionary typically contains parameters parsed via the parameters parser above.
Theenvdictionary contains all the environment variables. You can thus access them in your templates usingenv.USER,env.LANG,env.PRODUCT_MODULE_NAME, etc.
#19
Internal Changes
- Renamed
SwiftTemplatetoStencilSwiftTemplate.
David Jennes #14 - Refactor stencil swift extensions registration for easier use with an existing
Extension.
David Jennes #16 - Refactor stencil node tests to not use templates and output files.
David Jennes #17
Pre-1.0.0
See SwitftGen's own CHANGELOG pre SwiftGen 4.2 version, before the refactoring that led us to split the code in frameworks