open-merou

Open Mérou, a free iOS app for the Oceanic+ underwater iPhone housing
git clone https://git.schurger.org/open-merou.git
Log | Files | Refs | README | LICENSE

Makefile (1513B)


      1 # The sources live on this host; Xcode runs on a Mac reachable over SSH (CHUNGA), in the REMOTE directory.
      2 # RemoraKit (a separate repository) is expected next to this one, here (KIT) and on the Mac
      3 # (REMOTE_KIT): project.yml refers to it as ../remora-kit.
      4 CHUNGA ?= chunga
      5 REMOTE ?= src/perso/open-merou
      6 KIT ?= ../remora-kit
      7 REMOTE_KIT ?= $(dir $(REMOTE))remora-kit
      8 RSYNC = rsync -a --delete --exclude .git --exclude .claude --exclude captures --exclude '*.xcodeproj' --exclude build --exclude .build --exclude .swiftpm
      9 DEST ?= platform=iOS Simulator,name=OpenMerou test iPhone
     10 
     11 .PHONY: sync project build test release
     12 
     13 sync:
     14 	$(RSYNC) ./ $(CHUNGA):$(REMOTE)/
     15 	$(RSYNC) $(KIT)/ $(CHUNGA):$(REMOTE_KIT)/
     16 
     17 project: sync
     18 	ssh $(CHUNGA) 'cd $(REMOTE) && xcodegen -q'
     19 
     20 build: project
     21 	ssh $(CHUNGA) 'cd $(REMOTE) && xcodebuild -quiet -scheme OpenMerou -destination "$(DEST)" build'
     22 
     23 test: project
     24 	ssh $(CHUNGA) 'cd $(REMOTE) && xcodebuild -quiet -scheme OpenMerou -destination "$(DEST)" test'
     25 
     26 # Archive, upload to TestFlight (with a safeguard: altool sometimes hangs), then, once the build is processed:
     27 # test notes, internal group, "Externes" group and beta review. Nothing to do by hand.
     28 release: project
     29 	ssh $(CHUNGA) 'cd $(REMOTE) && security unlock-keychain -p "$$(cat ~/.keyring_secret)" ~/Library/Keychains/login.keychain-db && fastlane ios archive 2>&1 | grep -E "ARCHIVE|EXPORT|rror:" | grep -v CoreSimulator'
     30 	ssh $(CHUNGA) 'cd $(REMOTE) && ./tools/upload.sh'
     31 	./tools/wait-beta.sh $(CHUNGA) $(REMOTE)