From 4af0c61d564da7369ac84480386be1a7d100fa7a Mon Sep 17 00:00:00 2001 From: Eneko Alonso Date: Wed, 9 Aug 2017 09:27:32 -0700 Subject: [PATCH] Release 0.3.0 (#33) - Updates for Release 0.3.0 --- CHANGELOG.md | 55 ++++++++++++++++++++++++++++++++++++++----------- Conduit.podspec | 8 ++++--- Package.swift | 3 --- 3 files changed, 48 insertions(+), 18 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6831f488..613875eb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,30 +1,61 @@ ## Master #### Breaking -- Remove unnecessary casting to `NSError` on `SessionTaskCompletion`. -- `XMLNode.children` is no longer optional, defaults to empty array. +- None + +#### Enhancements +- None + +#### Bug Fixes +- None + + +## 0.3.0 + +#### Breaking - Auth shared `URLSessionClient` defaults to background operation queue. -- Rename `XMLNode.value` property to `text`. - Update `URLSessionClient` to return `HTTPURLResponse` for easy retrieval of HTTP status codes. +- Changes on `XMLNode`: + - Rename `value` property to `text`. + - Update `XMLNode` subscript method to return `XMLNode?`. + - Add `.firstLevel` traversal for `XMLNode` to retrieve direct children only. + - Remove `xmlValue()` in favor of `description`. + - Conform to `LosslessStringConvertible` protocol. + - Rename `value()` to `getValue()`. + - Rename `get(named:)` to `getValue(named:)`. +- Changes on `XML`: + - Remove `xmlValue()` in favor of `description`. + - Conform to `LosslessStringConvertible` protocol. - Remove `XMLNodeIndex`. -- Update `XMLNode` subscript method to return `XMLNode?`. -- Add `.firstLevel` traversal for `XMLNode` to retrieve direct children only. -- Remove `xmlValue()` from `XMLNode` and `XML` classes, in favor of `description`. -- Update `XMLNode` and `XML` to conform to `LosslessStringConvertible` protocol. #### Enhancements - Shared `URLSessionClient` with default background operation queue. - Enhancements to `XMLNode` class: - - `init` has been improved to allow passing value, attributes and/or children (optional parameters). - - `value` passed can be any `CustomStringConvertible`. - - `nodes(named:)` method finds an retrieves a list of descendant nodes matching the given name. + - `value` passed to `init` can be any `CustomStringConvertible`. - `node(named:)` retrieves the first descendant found with the given name and throws an exception if no matches found. - - `getValue()` method retrieves the value converted to a given type that can be constructed from a string by conforming to `LosslessStringConvertible`, or `nil` if the node contains no value. - - `getValue(named:)` generic method returns the value of the first descendant node matching the given name, converted to any given type that can be constructed from a string by conforming to `LosslessStringConvertible`. - `XMLNode` can be created from Swift dictionaries of `[String: CustomStringConvertible]` (aka. `XMLDictionary`). + - Add optional counterparts for `getValue()` and `getValue(named:)` #### Bug Fixes - None + +## 0.2.0 + +#### Breaking +- Remove unnecessary casting to `NSError` on `SessionTaskCompletion`. +- `XMLNode.children` is no longer optional, defaults to empty array. + +#### Enhancements +Enhancements to `XMLNode` class: +- `init` has been improved to allow passing value, attributes and/or children (optional parameters). +- `nodes(named:)` method finds an retrieves a list of descendant nodes matching the given name. +- `getValue()` generic method returns the node text value, if any, converted to any given type that can be constructed from a string by conforming to `LosslessStringConvertible`. +- `get(_:)` generic method returns the value of the first descendant node matching the given name, converted to any given type that can be constructed from a string by conforming to `LosslessStringConvertible`. + +#### Bug Fixes +- None + + ## 0.1.0 - Initial Release diff --git a/Conduit.podspec b/Conduit.podspec index 98bbd39d..d0fe21ad 100644 --- a/Conduit.podspec +++ b/Conduit.podspec @@ -1,11 +1,13 @@ +$version = '0.3.0' + Pod::Spec.new do |spec| spec.name = 'Conduit' - spec.version = '0.0.1' + spec.version = $version # spec.license = { :type -> 'MIT' } spec.homepage = 'https://github.com/mindbody/Conduit' spec.author = 'Conduit Contributors' spec.summary = 'Robust Swift networking for web APIs' - spec.source = { :git => 'https://github.com/mindbody/Conduit.git', :tag => '0.0.1' } + spec.source = { :git => 'https://github.com/mindbody/Conduit.git', :tag => $version } spec.source_files = 'Sources/**/*.swift' spec.ios.framework = 'SystemConfiguration' spec.tvos.framework = 'SystemConfiguration' @@ -14,4 +16,4 @@ Pod::Spec.new do |spec| spec.watchos.deployment_target = '2.0' spec.tvos.deployment_target = '9.0' spec.osx.deployment_target = '10.10' -end \ No newline at end of file +end diff --git a/Package.swift b/Package.swift index 58d72387..46f55695 100644 --- a/Package.swift +++ b/Package.swift @@ -8,9 +8,6 @@ import PackageDescription -/// Note that `swift test` is currently unsupported since there is currently no support for bundled resources -/// Relevant Bug: https://bugs.swift.org/browse/SR-2866 - let package = Package( name: "Conduit", dependencies : []