-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathMakefile
42 lines (34 loc) · 898 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
EXECUTE?=kuri
PROJECT?=Kuri
PACKAGE?=Kuri
DEMO_DIRECTORY?=KuriDemo
BUILD_DIRECTORY?=.build
RELEASE_BINARY_DIRECTORY?=$(BUILD_DIRECTORY)/release/$(PROJECT)
install: release
rm -rf ./bin/$(EXECUTE)
mkdir -p ./bin
cp -f $(RELEASE_BINARY_DIRECTORY) bin/$(EXECUTE)
release:
swift build -c release
build:
swift build
localmint:
$(eval HASH=$(shell git rev-parse HEAD))
echo "COMMIT HASH is $(HASH)"
git tag $(HASH)
mint install file://$(shell pwd -P)@$(HASH)
git tag -d $(HASH)
xcodeproj:
swift package generate-xcodeproj
clean:
swift package clean
rm -rf $(BUILD_DIRECTORY) $(PROJECT).xcodeproj
test: build xcodeproj
xcodebuild clean build test -project $(PROJECT).xcodeproj \
-scheme $(PACKAGE) \
-destination platform="macOS" \
-enableCodeCoverage YES \
-derivedDataPath .build/derivedData \
CODE_SIGN_IDENTITY="" \
CODE_SIGNING_REQUIRED=NO \
ONLY_ACTIVE_ARCH=NO