This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
@available(iOS 13.0, *) | |
public struct IfLetElseView<Value, IfContent: View, ElseContent: View>: View { | |
private let value: Value? | |
private let ifContent: (Value) -> IfContent | |
private let elseContent: () -> ElseContent | |
public init(_ value: Value?, | |
@ViewBuilder ifContent: @escaping (Value) -> IfContent, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Fastlane | |
module Actions | |
class CheckoutBranchForJiraIssueAction < Action | |
def self.run(params) | |
key = params[:key].split('/').last | |
branch_name = self.branch_name(key) | |
branch = "#{key}_#{branch_name}" | |
sh "git fetch" | |
ref_count = sh "git show-ref refs/remotes/origin/#{branch} | wc -l" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
submit-appstore: | |
only: | |
refs: | |
- develop | |
needs: [deliver-appstore] | |
stage: submit-appstore | |
tags: [osx] | |
allow_failure: false | |
script: | |
- bundle exec fastlane submit_app |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
desc "Submit app" | |
lane :submit_app do | |
deliver( | |
build_number: "latest", | |
skip_metadata: true, | |
skip_screenshots: true, | |
skip_binary_upload: true, | |
force: true, | |
submit_for_review: true, | |
phased_release: true, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
desc "Fetches the provisioning profiles so you can build locally and deploy to your device" | |
lane :certificates do | |
match(type: "development", app_identifier: ["your_app_identifier"]) | |
match(type: "adhoc", app_identifier: ["your_app_identifier"]) | |
match(type: "appstore", app_identifier: ["your_app_identifier"]) | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
desc "Merges develop into your feature branch \"Pre-push git hook\"" | |
lane :merge_develop_if_needed do | |
current_branch = Actions.sh("git rev-parse --abbrev-ref HEAD") | |
next unless current_branch.start_with?(ENV['JIRA_PROJECT']) | |
Actions.sh("git fetch && git merge origin/#{ENV['DEVELOP_BRANCH']} --no-edit") | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
desc "Create and checkout git branch for a JIRA ticket" | |
lane :checkout do |options| | |
ticket = options[:ticket] | |
if !ticket | |
ticket = prompt(text: "JIRA ticket key e.g. AMI-XYZ: ") | |
end | |
checkout_branch_for_jira_issue(key: ticket) | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
unit-tests: | |
only: | |
- external_pull_requests | |
stage: unit-tests | |
tags: [osx] | |
script: | |
- bundle exec fastlane pull_request | |
artifacts: | |
when: always | |
paths: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
desc "Runs pull request workflow \"Open a pull request\"" | |
lane :pull_request do | |
scan(scheme: "Pull Request", skip_build: true) | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
desc "Runs all the regression UI Tests" | |
lane :regression do | |
scan(scheme: "UAT Regression", skip_build: true) | |
end |
OlderNewer