Skip to content

Commit

Permalink
Merge pull request #43 from RedMadRobot/feature/disable-sandbox
Browse files Browse the repository at this point in the history
Build with --disable-sandbox
  • Loading branch information
Alexander-Ignition authored Nov 26, 2021
2 parents b6455e5 + c3080b4 commit 554d68b
Showing 1 changed file with 20 additions and 13 deletions.
33 changes: 20 additions & 13 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,31 +1,38 @@
test:
$(call test)
PACKAGE_PATH = Packages/CatbirdApp
BUILD_CATBIRD_APP = swift build \
--disable-sandbox \
--configuration release \
--package-path $(PACKAGE_PATH)

test-api:
swift test --enable-code-coverage
$(call cov_report,Catbird)
cd Packages/CatbirdApp; $(call test)
cd Packages/CatbirdApp; $(call cov_report,CatbirdApp)

test-app:
swift test --enable-code-coverage --disable-automatic-resolution --package-path $(PACKAGE_PATH)
cd $(PACKAGE_PATH) && $(call cov_report,CatbirdApp)

test: test-api test-app

release:
cd Packages/CatbirdApp && swift build -c release
cp Packages/CatbirdApp/.build/release/catbird ./catbird
$(BUILD_CATBIRD_APP)
cp $(shell $(BUILD_CATBIRD_APP) --show-bin-path)/catbird ./catbird

archive:
zip -v catbird.zip catbird LICENSE
cd Packages/CatbirdApp && zip ../../catbird.zip -r -v start.sh stop.sh Public Resources
cd Packages/CatbirdAPI && zip ../../catbird.zip -r -v Sources/CatbirdAPI
cd $(PACKAGE_PATH) && zip ../../catbird.zip -r -v start.sh stop.sh Public Resources
cd Packages/CatbirdAPI/ && zip ../../catbird.zip -r -v Sources/CatbirdAPI

update:
swift package update
swift package update --package-path $(PACKAGE_PATH)

clean:
swift package clean
swift package clean --package-path $(PACKAGE_PATH)

lint:
bundle exec pod spec lint

define test
swift test --enable-code-coverage --disable-automatic-resolution
endef

define cov_report
xcrun llvm-cov report \
.build/debug/$(1)PackageTests.xctest/Contents/MacOS/$(1)PackageTests \
Expand Down

0 comments on commit 554d68b

Please sign in to comment.