Skip to content

Commit

Permalink
Update makefile to properly update submodules
Browse files Browse the repository at this point in the history
  • Loading branch information
dominiklohmann committed Feb 19, 2019
1 parent d2501ac commit cf48aaa
Showing 1 changed file with 18 additions and 7 deletions.
25 changes: 18 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,17 +1,28 @@
.PHONY: all
all: install

25th-hour.heic:
git submodule update external/wallpapper
swift run --package-path external/wallpapper \
PRE := "[25th-hour]"

external/wallpapper/.git:
@echo ${PRE} Fetching submodule wallpapper
@git submodule update --init external/wallpapper

external/macos-wallpaper/.git:
@echo ${PRE} Fetching submodule mcaos-wallpaper
@git submodule update --init external/macos-wallpaper

25th-hour.heic: external/wallpapper/.git
@echo ${PRE} Building dynamic wallpaper
@swift run --package-path external/wallpapper \
wallpapper -i wallpapper.json -o 25th-hour.heic

.PHONY: install
install: 25th-hour.heic
git submodule update external/macos-wallpaper
swift run --package-path external/macos-wallpaper \
install: 25th-hour.heic external/macos-wallpaper/.git
@echo ${PRE} Setting wallpaper on all visible desktops
@swift run --package-path external/macos-wallpaper \
wallpaper set 25th-hour.heic

.PHONY: all
clean:
rm -f 25th-hour.heic
@echo ${PRE} Removing dynamic wallpaper
@rm -f 25th-hour.heic

0 comments on commit cf48aaa

Please sign in to comment.