<NME> Makefile
<BEF> BUILD_TOOL = xcodebuild
BUILD_SCHEME = SQLite Mac
IOS_SIMULATOR = iPhone 6s
IOS_VERSION = 9.3
ifeq ($(BUILD_SCHEME),SQLite iOS)
	BUILD_ARGUMENTS = -scheme "$(BUILD_SCHEME)" -destination "platform=iOS Simulator,name=$(IOS_SIMULATOR),OS=$(IOS_VERSION)"
else
	BUILD_ARGUMENTS = -scheme "$(BUILD_SCHEME)"
endif

XCPRETTY := $(shell command -v xcpretty)
TEST_ACTIONS := clean build build-for-testing test-without-building

default: test

build:
	$(BUILD_TOOL) $(BUILD_ARGUMENTS)

lint:
	swiftlint --strict
lint-fix:
	swiftlint lint fix

test:
ifdef XCPRETTY
	@set -o pipefail && $(BUILD_TOOL) $(BUILD_ARGUMENTS) $(TEST_ACTIONS) | $(XCPRETTY) -c
else
	$(BUILD_TOOL) $(BUILD_ARGUMENTS) $(TEST_ACTIONS)
endif

clean:
	$(BUILD_TOOL) $(BUILD_ARGUMENTS) clean

repl:
	@$(BUILD_TOOL) $(BUILD_ARGUMENTS) -derivedDataPath $(TMPDIR)/SQLite.swift > /dev/null && \
		swift -F '$(TMPDIR)/SQLite.swift/Build/Products/Debug'

sloc:
	@zsh -c "grep -vE '^ *//|^$$' Sources/**/*.{swift,h,m} | wc -l"

.PHONY: test clean repl sloc

<MSG> Bump iOS version
<DFF> @@ -1,7 +1,7 @@
 BUILD_TOOL = xcodebuild
 BUILD_SCHEME = SQLite Mac
 IOS_SIMULATOR = iPhone 6s
-IOS_VERSION = 9.3
+IOS_VERSION = 10.3
 ifeq ($(BUILD_SCHEME),SQLite iOS)
 	BUILD_ARGUMENTS = -scheme "$(BUILD_SCHEME)" -destination "platform=iOS Simulator,name=$(IOS_SIMULATOR),OS=$(IOS_VERSION)"
 else

{'commit': 'diff --git a/Makefile b/Makefile\nindex d4f51d5..adab1d8 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -1,7 +1,7 @@\n BUILD_TOOL = xcodebuild\n BUILD_SCHEME = SQLite Mac\n IOS_SIMULATOR = iPhone 6s\n-IOS_VERSION = 9.3\n+IOS_VERSION = 10.3\n ifeq ($(BUILD_SCHEME),SQLite iOS)\n \tBUILD_ARGUMENTS = -scheme "$(BUILD_SCHEME)" -destination "platform=iOS Simulator,name=$(IOS_SIMULATOR),OS=$(IOS_VERSION)"\n else\n', 'commit_subject': 'Bump iOS version', 'repo_name': 'stephencelis/SQLite.swift', 'committer': {'name': 'Jan Berkel', 'email': '14e793d896ddc8ca6911747228e86464cf420065@berkel.fr', 'time_sec': '1490855041', 'tz_offset': '120', 'date': {'seconds': '1490855041'}}, 'commit_tree': 'fd42aa81aa23ec49f9a16be4276712ec113e0be1', 'commit_message': 'Bump iOS version', 'language_name': 'Ruby', 'license': 'mit', 'hunks': '@@ -1,7 +1,7 @@\n BUILD_TOOL = xcodebuild\n BUILD_SCHEME = SQLite Mac\n IOS_SIMULATOR = iPhone 6s\n-IOS_VERSION = 9.3\n+IOS_VERSION = 10.3\n ifeq ($(BUILD_SCHEME),SQLite iOS)\n \tBUILD_ARGUMENTS = -scheme "$(BUILD_SCHEME)" -destination "platform=iOS Simulator,name=$(IOS_SIMULATOR),OS=$(IOS_VERSION)"\n else\n', 'addition_count': 1, 'deletion_count': 1, 'src_file': 'a/Makefile', 'tgt_file': 'b/Makefile', 'file_extension': '', 'before_file': 'BUILD_TOOL = xcodebuild\nBUILD_SCHEME = SQLite Mac\nIOS_SIMULATOR = iPhone 6s\nIOS_VERSION = 9.3\nifeq ($(BUILD_SCHEME),SQLite iOS)\n\tBUILD_ARGUMENTS = -scheme "$(BUILD_SCHEME)" -destination "platform=iOS Simulator,name=$(IOS_SIMULATOR),OS=$(IOS_VERSION)"\nelse\n\tBUILD_ARGUMENTS = -scheme "$(BUILD_SCHEME)"\nendif\n\nXCPRETTY := $(shell command -v xcpretty)\nTEST_ACTIONS := clean build build-for-testing test-without-building\n\ndefault: test\n\nbuild:\n\t$(BUILD_TOOL) $(BUILD_ARGUMENTS)\n\nlint:\n\tswiftlint --strict\nlint-fix:\n\tswiftlint lint fix\n\ntest:\nifdef XCPRETTY\n\t@set -o pipefail && $(BUILD_TOOL) $(BUILD_ARGUMENTS) $(TEST_ACTIONS) | $(XCPRETTY) -c\nelse\n\t$(BUILD_TOOL) $(BUILD_ARGUMENTS) $(TEST_ACTIONS)\nendif\n\nclean:\n\t$(BUILD_TOOL) $(BUILD_ARGUMENTS) clean\n\nrepl:\n\t@$(BUILD_TOOL) $(BUILD_ARGUMENTS) -derivedDataPath $(TMPDIR)/SQLite.swift > /dev/null && \\\n\t\tswift -F \'$(TMPDIR)/SQLite.swift/Build/Products/Debug\'\n\nsloc:\n\t@zsh -c "grep -vE \'^ *//|^$$\' Sources/**/*.{swift,h,m} | wc -l"\n\n.PHONY: test clean repl sloc\n', 'message': 'Bump iOS version', 'author_name': 'Jan Berkel', 'lang': 'Makefile'}