2016-10-05 23:19:23 +02:00
|
|
|
# Make sure we're failing even though we pipe to xcpretty
|
2016-10-10 20:48:35 +02:00
|
|
|
SHELL=/bin/bash -o pipefail -o errexit
|
2016-10-05 23:19:23 +02:00
|
|
|
|
|
|
|
WORKING_DIR = ./
|
2018-10-22 22:01:37 +02:00
|
|
|
THIRD_PARTY_DIR = $(WORKING_DIR)/ThirdParty
|
2016-10-10 20:48:35 +02:00
|
|
|
SCHEME = Signal
|
2017-09-26 03:51:15 +02:00
|
|
|
XCODE_BUILD = xcrun xcodebuild -workspace $(SCHEME).xcworkspace -scheme $(SCHEME) -sdk iphonesimulator
|
2016-10-10 20:48:35 +02:00
|
|
|
|
2016-11-01 20:02:15 +01:00
|
|
|
.PHONY: build test retest clean dependencies
|
2016-10-05 23:19:23 +02:00
|
|
|
|
|
|
|
default: test
|
|
|
|
|
2017-03-14 00:20:00 +01:00
|
|
|
update_dependencies:
|
2017-07-11 19:14:21 +02:00
|
|
|
bundle exec pod update
|
2017-03-15 23:50:34 +01:00
|
|
|
carthage update --platform iOS
|
2017-03-14 00:20:00 +01:00
|
|
|
|
2019-01-03 18:46:22 +01:00
|
|
|
setup:
|
|
|
|
rbenv install -s
|
|
|
|
gem install bundler
|
|
|
|
bundle install
|
|
|
|
|
2016-11-01 20:02:15 +01:00
|
|
|
dependencies:
|
2016-10-05 23:19:23 +02:00
|
|
|
cd $(WORKING_DIR) && \
|
2016-10-10 22:02:09 +02:00
|
|
|
git submodule update --init
|
2018-10-22 22:01:37 +02:00
|
|
|
cd $(THIRD_PARTY_DIR) && \
|
|
|
|
carthage build --platform iOS
|
2016-10-10 20:48:35 +02:00
|
|
|
|
2016-11-01 20:02:15 +01:00
|
|
|
build: dependencies
|
2016-10-10 20:48:35 +02:00
|
|
|
cd $(WORKING_DIR) && \
|
|
|
|
$(XCODE_BUILD) build | xcpretty
|
2016-10-05 23:19:23 +02:00
|
|
|
|
2017-07-21 15:42:58 +02:00
|
|
|
test:
|
2019-01-03 18:46:22 +01:00
|
|
|
bundle exec fastlane test
|
2017-07-11 19:14:21 +02:00
|
|
|
|
2018-10-22 22:01:37 +02:00
|
|
|
clean: clean_carthage
|
2016-10-10 20:48:35 +02:00
|
|
|
cd $(WORKING_DIR) && \
|
2017-09-26 03:51:15 +02:00
|
|
|
$(XCODE_BUILD) clean | xcpretty
|
2016-10-05 23:19:23 +02:00
|
|
|
|
2018-10-22 22:01:37 +02:00
|
|
|
clean_carthage:
|
|
|
|
cd $(THIRD_PARTY_DIR) && \
|
|
|
|
rm -fr Carthage/Build
|
|
|
|
|
2017-09-26 03:51:15 +02:00
|
|
|
# Migrating across swift versions requires me to run this sometimes
|
|
|
|
clean_carthage_cache:
|
|
|
|
rm -fr ~/Library/Caches/org.carthage.CarthageKit/
|