Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make all SKIP_MODULES=1 to not update modules #137

Merged
merged 2 commits into from
Aug 15, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ export PIP
# Derived variable to allow filtering -e, or inserting other options
# (the option --editable must always be last and only applies to src install)
PIP_OPTIONS_E = $(filter-out -e,$(PIP_OPTIONS))
# Set to 1 to skip all submodule updates. For development.
SKIP_MODULES = 0
GIT_RECURSIVE = # --recursive
# Required and optional Tesseract models.
ALL_TESSERACT_MODELS = eng equ osd $(TESSERACT_MODELS)
Expand Down Expand Up @@ -108,11 +110,13 @@ modules: $(OCRD_MODULES)
# but bypass updates if we have no repo here (e.g. Docker build)
ifneq (,$(wildcard .git))
$(OCRD_MODULES): always-update
ifneq ($(SKIP_MODULES),1)
sem --fg --id ocrd_all_git git submodule sync $(GIT_RECURSIVE) $@
if git submodule status $(GIT_RECURSIVE) $@ | grep -qv '^ '; then \
sem --fg --id ocrd_all_git git submodule update --init $(GIT_RECURSIVE) $@ && \
touch $@; fi
endif
endif

deinit: clean
.PHONY: deinit
Expand Down