Skip to content

Commit

Permalink
Merge branch 'release/1.6.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
JoeMatt committed Feb 15, 2021
2 parents daae5be + 87028b9 commit 65df0c4
Show file tree
Hide file tree
Showing 185 changed files with 4,944 additions and 5,054 deletions.
12 changes: 12 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# These are supported funding model platforms

github: [JoeMatt, lkzhao, SD10, kuyazee] # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: herotransitions # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
96 changes: 42 additions & 54 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Unit Test

on:
on:
pull_request:
paths:
- "**.swift"
Expand All @@ -9,94 +9,82 @@ on:
- "**.h"
- "**.podspec"
- "Podfile"
- "Podfile.lock"
- "test.yml"
jobs:
iOS:
name: Test iOS
swiftpm:
name: Test iOS (swiftpm)
runs-on: macOS-latest
env:
DEVELOPER_DIR: /Applications/Xcode_11.1.app/Contents/Developer
strategy:
matrix:
destination: [
'platform=iOS Simulator,OS=13.1,name=iPhone 11'
]
DEVELOPER_DIR: /Applications/Xcode_12.4.app/Contents/Developer
steps:
- name: Checkout
uses: actions/checkout@master
- name: iOS - ${{ matrix.destination }}
- name: iOS - Swift PM
run: |
pod install
set -o pipefail && xcodebuild clean test -workspace Hero.xcworkspace -scheme Hero -destination "${destination}" -parallelizeTargets -showBuildTimingSummary -enableThreadSanitizer YES -enableCodeCoverage YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO | xcpretty
bash <(curl -s https://codecov.io/bash)
env:
destination: ${{ matrix.destination }}
- name: Upload Code Coverage
run: |
bash <(curl -s https://codecov.io/bash)
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
iOS-legacy:
set -o pipefail && swift test --parallel
iOS:
name: Test iOS
runs-on: macOS-latest
env:
DEVELOPER_DIR: /Applications/Xcode_11.1.app/Contents/Developer
DEVELOPER_DIR: /Applications/Xcode_12.4.app/Contents/Developer
strategy:
matrix:
destination: [
'platform=iOS Simulator,OS=10.3.1,name=iPhone 7'
'platform=iOS Simulator,OS=14.4,name=iPhone 12'
]
steps:
- name: Checkout
uses: actions/checkout@master

- name: iOS - ${{ matrix.destination }}
run: |
xcversion simulators --install='iOS 10.3.1'
pod install
set -o pipefail && xcodebuild clean test -workspace Hero.xcworkspace -scheme Hero -destination "${destination}" -parallelizeTargets -showBuildTimingSummary -enableThreadSanitizer YES -enableCodeCoverage YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO | xcpretty
bash <(curl -s https://codecov.io/bash)
env:
destination: ${{ matrix.destination }}
- name: Upload Code Coverage
run: |
set -o pipefail && xcodebuild clean test -workspace Hero.xcworkspace -scheme Hero -destination "${destination}" -configuration "Debug" -showBuildTimingSummary -enableThreadSanitizer YES -enableCodeCoverage YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=YES | xcpretty
bash <(curl -s https://codecov.io/bash)
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
iOS-legacy:
name: Test iOS
runs-on: macOS-latest
env:
DEVELOPER_DIR: /Applications/Xcode_11.1.app/Contents/Developer
strategy:
matrix:
destination: [
'platform=iOS Simulator,OS=10.3.1,name=iPhone 7'
]
steps:
- name: Checkout
uses: actions/checkout@master
- name: iOS - ${{ matrix.destination }}
run: |
xcversion simulators --install='iOS 10.3.1'
pod install
set -o pipefail && xcodebuild clean test -workspace Hero.xcworkspace -scheme Hero -destination "${destination}" -parallelizeTargets -showBuildTimingSummary -enableThreadSanitizer YES -enableCodeCoverage YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO | xcpretty
bash <(curl -s https://codecov.io/bash)
env:
destination: ${{ matrix.destination }}
- name: Upload Code Coverage
run: |
bash <(curl -s https://codecov.io/bash)
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
# iOS-legacy:
# name: Test iOS
# runs-on: macOS-latest
# env:
# DEVELOPER_DIR: /Applications/Xcode_10.3.1.app/Contents/Developer
# strategy:
# matrix:
# destination: [
# 'platform=iOS Simulator,OS=10.3.1,name=iPhone 7'
# ]
# steps:
# - name: Checkout
# uses: actions/checkout@master
# - name: iOS - ${{ matrix.destination }}
# run: |
# xcversion simulators --install='iOS 10.3.1'
# pod install
# set -o pipefail && xcodebuild clean test -workspace Hero.xcworkspace -scheme Hero -destination "${destination}" -parallelizeTargets -showBuildTimingSummary -enableThreadSanitizer YES -enableCodeCoverage YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO | xcpretty
# bash <(curl -s https://codecov.io/bash)
# env:
# destination: ${{ matrix.destination }}
# - name: Upload Code Coverage
# run: |
# bash <(curl -s https://codecov.io/bash)
# env:
# CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
tvOS:
name: Test tvOS
runs-on: macOS-latest
env:
DEVELOPER_DIR: /Applications/Xcode_11.1.app/Contents/Developer
DEVELOPER_DIR: /Applications/Xcode_12.4.app/Contents/Developer
strategy:
matrix:
destination: [
'platform=tvOS Simulator,OS=13.0,name=Apple TV 4K'
'platform=tvOS Simulator,OS=14.3,name=Apple TV 4K'
]

steps:
Expand All @@ -105,6 +93,6 @@ jobs:
- name: tvOS - ${{ matrix.destination }}
run: |
pod install
set -o pipefail && xcodebuild clean build -workspace Hero.xcworkspace -scheme "Hero (tvOS)" -destination "${destination}" -parallelizeTargets -showBuildTimingSummary -enableThreadSanitizer YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO | xcpretty
env:
set -o pipefail && xcodebuild clean build -workspace Hero.xcworkspace -scheme "Hero (tvOS)" -destination "${destination}" -parallelizeTargets -showBuildTimingSummary -enableThreadSanitizer YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=YES | xcpretty
env:
destination: ${{ matrix.destination }}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,4 @@ node_modules
_book
xcodebuild.log
.swiftpm
/.bundle
4 changes: 2 additions & 2 deletions .jazzy.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# ---- About ----
module: Hero
module_version: 1.5.0
module_version: 1.6.0
author: HeroTransitions
readme: README.md
copyright: 'See [license](https://github.com/HeroTransitions/Hero/blob/develop/LICENSE) for more details.'
Expand All @@ -9,7 +9,7 @@ copyright: 'See [license](https://github.com/HeroTransitions/Hero/blob/develop/L
author_url: https://herotransitions.github.io/Hero/
dash_url: https://herotransitions.github.io/Hero/docsets/Hero.xml
github_url: https://github.com/HeroTransitions/Hero/
github_file_prefix: https://github.com/HeroTransitions/Hero/tree/1.5.0/
github_file_prefix: https://github.com/HeroTransitions/Hero/tree/1.6.0/

# ---- Sources ----
podspec: Hero.podspec
Expand Down
16 changes: 8 additions & 8 deletions .makefiles/ios.mk
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ pre_setup:
check_for_ruby:
$(info Checking for Ruby ...)

ifeq ($(RUBY),)
ifeq ($(RUBY),)
$(error Ruby is not installed)
endif

Expand All @@ -109,7 +109,7 @@ update_homebrew:
install_swift_lint:
$(info Install swiftlint ...)

ifneq ($(SWIFTLINT),)
ifneq ($(SWIFTLINT),)
brew install swiftlint
else
$(info Already have, skipping.)
Expand All @@ -132,7 +132,7 @@ install_ruby_gems:
install_carthage:
$(info Install Carthage ...)

ifneq ($(CARTHAGE),)
ifneq ($(CARTHAGE),)
brew install carthage
else
$(info Already have, skipping.)
Expand All @@ -141,7 +141,7 @@ endif
install_carting:
$(info Install Carting ...)

ifneq ($(CARTING),)
ifneq ($(CARTING),)
brew install artemnovichkov/projects/carting
else
$(info Already have, skipping.)
Expand All @@ -150,7 +150,7 @@ endif
install_swiftgen:
$(info Install Swift-Gen (https://github.com/SwiftGen/SwiftGen) ...)

ifneq ($(SWIFTGEN),)
ifneq ($(SWIFTGEN),)
brew install swiftgen
else
$(info Already have, skipping.)
Expand All @@ -160,7 +160,7 @@ gitpull:
$(info Pulling new commits ...)

git pull

#> -- QA Task Runners --

codecov_upload:
Expand All @@ -170,7 +170,7 @@ codecov_upload:
danger_pr:
bundle exec danger pr "$(GITHUB_URL:/=)/pull/$(PULL)"

danger:
danger:
bundle exec danger

#> SwiftLint autocorrect
Expand All @@ -181,7 +181,7 @@ autocorrect:

#> Run test on all targets
test:
xcodebuild test -scheme $(TEST_SCHEME) -workspace $(WORKSPACE) | tee xcodebuild.log | xcpretty
xcodebuild test -scheme $(TEST_SCHEME) -workspace $(WORKSPACE) -destination 'platform=iOS Simulator,OS=14.4,name=iPhone 12' -parallelizeTargets -showBuildTimingSummary -enableThreadSanitizer YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=YES | tee xcodebuild.log | xcpretty

#> -- Building --

Expand Down
5 changes: 2 additions & 3 deletions .swiftlint.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
disabled_rules: # rule identifiers to exclude from running
- missing_docs
- unused_closure_parameter
- force_cast
- identifier_name
- weak_delegate
- variable_name
- cyclomatic_complexity
- function_body_length
- todo
Expand Down Expand Up @@ -52,7 +51,7 @@ type_name:
- T
- t

variable_name:
identifier_name:
min_length: # only min_length
error: 3 # only error
excluded: # excluded via string array
Expand Down
23 changes: 22 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,29 @@ The changelog for `Hero`. Also see the [releases](https://github.com/HeroTransit

--------------------------------------

## [1.5.0](https://github.com/HeroTransitions/Hero/releases/tag/1.5.0)
## [1.6.0](https://github.com/HeroTransitions/Hero/releases/tag/1.6.0)
### Added

- #695 - Swift 5 support
- #628 - Swift Package Manager Support
- #623 - Swift UI support and example
- #681 - Application extension target support
- #595 - Add Accio supported badge
- #619 - XCode 11/12 support in example
- CI/CD improvements
### Changed

- #648 - Updated iOS version support
- #576 - Usage guide updates

### Fixed

- #698 - Warnings fix
- #585 - replaceViewControllers now calls the completion
- #559 - Resuming property animator from current fraction
- #465 - fix keyboard transition

## [1.5.0](https://github.com/HeroTransitions/Hero/releases/tag/1.5.0)
### Added

- Use custom snapshot for views that implement `HeroCustomSnapshotView`.
Expand Down
2 changes: 1 addition & 1 deletion Examples/AppStoreCardExample.swift
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ class AppStoreViewController2: ExampleBaseViewController {
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent neque est, hendrerit vitae nibh ultrices, accumsan elementum ante. Phasellus fringilla sapien non lorem consectetur, in ullamcorper tortor condimentum. Nulla tincidunt iaculis maximus. Sed ut urna urna. Nulla at sem vel neque scelerisque imperdiet. Donec ornare luctus dapibus. Donec aliquet ante augue, at pellentesque ipsum mollis eget. Cras vulputate mauris ac eleifend sollicitudin. Vivamus ut posuere odio. Suspendisse vulputate sem vel felis vehicula iaculis. Fusce sagittis, eros quis consequat tincidunt, arcu nunc ornare nulla, non egestas dolor ex at ipsum. Cras et massa sit amet quam imperdiet viverra. Mauris vitae finibus nibh, ac vulputate sapien.
"""

if #available(iOS 13.0, *) {
if #available(iOS 13.0, tvOS 13, *) {
contentCard.backgroundColor = .systemBackground
} else {
contentCard.backgroundColor = .white
Expand Down
2 changes: 1 addition & 1 deletion Examples/ExampleBaseViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class ExampleBaseViewController: UIViewController {

override func viewDidLoad() {
super.viewDidLoad()
if #available(iOS 13.0, *) {
if #available(iOS 13.0, tvOS 13, *) {
view.backgroundColor = .systemBackground
} else {
view.backgroundColor = .white
Expand Down
4 changes: 2 additions & 2 deletions Examples/MainViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ class MainViewController: UIViewController {

override func viewDidLoad() {
super.viewDidLoad()
if #available(iOS 13.0, *) {
if #available(iOS 13.0, tvOS 13, *) {
view.backgroundColor = UIColor.systemBackground
} else {
view.backgroundColor = .white
Expand All @@ -35,7 +35,7 @@ class MainViewController: UIViewController {
let viewSource = ClosureViewSource { (label: UILabel, data: SourceData, index) in
label.text = "\(index + 1). \(data.exampleTitle)"
label.textAlignment = .center
if #available(iOS 13.0, *) {
if #available(iOS 13.0, tvOS 13, *) {
label.textColor = .label
label.backgroundColor = .systemBackground
} else {
Expand Down
2 changes: 1 addition & 1 deletion Examples/MatchExample.swift
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class MatchExampleViewController2: ExampleBaseViewController {
blackView.cornerRadius = 8
view.addSubview(blackView)

if #available(iOS 13.0, *) {
if #available(iOS 13.0, tvOS 13, *) {
backgroundView.backgroundColor = .systemBackground
} else {
backgroundView.backgroundColor = .white
Expand Down
Loading

0 comments on commit 65df0c4

Please sign in to comment.