Skip to content

Commit

Permalink
docs: add bitprog help
Browse files Browse the repository at this point in the history
  • Loading branch information
rodrigomelo9 committed Jul 17, 2024
1 parent 42fe56d commit 995eae3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 10 deletions.
13 changes: 3 additions & 10 deletions docs/Makefile
Original file line number Diff line number Diff line change
@@ -1,24 +1,17 @@
# Minimal makefile for Sphinx documentation
#

# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = .
BUILDDIR = _build
HELPERS = $(BUILDDIR)/hdl2bit $(BUILDDIR)/prj2bit $(BUILDDIR)/bitprog

# Put it first so that "make" without argument is like "make help".
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

.PHONY: help Makefile

$(BUILDDIR)/hdl2bit $(BUILDDIR)/prj2bit:
$(HELPERS):
@mkdir -p $(@D)
@python3 ../pyfpga/helpers/$(@F).py -h > $@

# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile $(BUILDDIR)/hdl2bit $(BUILDDIR)/prj2bit
%: Makefile $(HELPERS)
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
5 changes: 5 additions & 0 deletions docs/helpers.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,8 @@ prj2bit
-------

.. literalinclude:: _build/prj2bit

bitprog
-------

.. literalinclude:: _build/bitprog

0 comments on commit 995eae3

Please sign in to comment.