Skip to content

Commit

Permalink
add task gh-pages-shift.
Browse files Browse the repository at this point in the history
  • Loading branch information
jiangxin committed Dec 31, 2011
1 parent 8a95fcf commit e01f9dc
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,16 @@ gh-pages: clean html
fi; \
git rm --cached -r -q _build/html

gh-pages-shift:
@if ! git rev-parse refs/heads/gh-pages^ >/dev/null 2>&1 ; then \
echo "Branch gh-pages not exists or only one commit, forgot check it out?" >&2; \
exit 1; \
fi
if git update-ref -m "shift from $$(git rev-parse refs/heads/gh-pages)" refs/heads/gh-pages $$(git rev-parse refs/heads/gh-pages^); then \
echo "gh-pages branch shift to last commit."; \
fi


doctest:
$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
@echo "Testing of doctests in the sources finished, look at the " \
Expand Down

0 comments on commit e01f9dc

Please sign in to comment.