25 lines
538 B
Makefile
25 lines
538 B
Makefile
#!/usr/bin/make
|
|
|
|
submodules:
|
|
git submodule init
|
|
git submodule update
|
|
|
|
submodule_update:
|
|
git submodule update
|
|
|
|
submodule_pull:
|
|
git submodule foreach "git pull"
|
|
|
|
submodule_check:
|
|
@-test -d .git -a .gitmodules && \
|
|
git submodule status \
|
|
| grep -q "^-" \
|
|
&& $(MAKE) submodules || true
|
|
@-test -d .git -a .gitmodules && git submodule sync
|
|
@-test -d .git -a .gitmodules && \
|
|
git submodule status \
|
|
| grep -q "^+" \
|
|
&& $(MAKE) submodule_update || true
|
|
|
|
.PHONY: submodule_check submodules submodule_update submodule_pull
|