X-Git-Url: https://git.distorted.org.uk/~mdw/stgit/blobdiff_plain/850c3a89476ba8608b2deeba109fa7def2607655..408fa7cbdbf88632a7a59b5207e7f564380ed2a6:/Makefile diff --git a/Makefile b/Makefile index 9322fe0..0fa5c6a 100644 --- a/Makefile +++ b/Makefile @@ -4,10 +4,20 @@ PYTHON ?= python TEST_PATCHES ?= .. -all: +all: build $(PYTHON) setup.py build -install: +build: stgit/commands/cmdlist.py stgit-completion.bash + +ALL_PY = $(shell find stgit -name '*.py') + +stgit/commands/cmdlist.py: $(ALL_PY) + $(PYTHON) stg-build --py-cmd-list > $@ + +stgit-completion.bash: $(ALL_PY) + $(PYTHON) stg-build --bash-completion > $@ + +install: build $(PYTHON) setup.py install --prefix=$(prefix) --root=$(DESTDIR) --force doc: @@ -19,10 +29,10 @@ install-doc: install-html: $(MAKE) -C Documentation install-html -test: +test: build cd t && $(MAKE) all -test_patches: +test_patches: build for patch in $$(stg series --noprefix $(TEST_PATCHES)); do \ stg goto $$patch && $(MAKE) test || break; \ done @@ -35,8 +45,13 @@ clean: rm -f stgit/*.pyc rm -f stgit/commands/*.pyc rm -f TAGS + rm -f stgit/commands/cmdlist.py tags: + ctags -R stgit/* + +TAGS: ctags -e -R stgit/* -.PHONY: all install doc install-doc install-html test test_patches clean +.PHONY: all build install doc install-doc install-html test test_patches \ + clean tags TAGS