Skip to content

Mkdocs #271

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

Merged
merged 12 commits into from
Mar 10, 2023
Merged
Show file tree
Hide file tree
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
Prev Previous commit
Build docs with Cython 3.0
  • Loading branch information
tazend committed Mar 8, 2023
commit f9af1c5bb6f4376e9f971112f446cc95091cd8f2
6 changes: 6 additions & 0 deletions doc_requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
cython>=3.0.0b1
wheel
setuptools
mkdocstrings[python]
mike
mkdocs-material
4 changes: 4 additions & 0 deletions docs/stylesheets/extra.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/* Maximum space for text block */
.md-grid {
max-width: 70%;
}
6 changes: 4 additions & 2 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,10 @@ plugins:
options:
filters: ["!^_"]
docstring_style: sphinx
show_signature: false
show_signature: true
show_root_heading: true
extra:
version:
provider: mike
provider: mike
extra_css:
- stylesheets/extra.css
25 changes: 3 additions & 22 deletions scripts/builddocs.sh
Original file line number Diff line number Diff line change
@@ -1,24 +1,5 @@
#!/bin/bash
#set -e

###########################################
# Build the docs and push to GitHub Pages #
###########################################

# Build docs for all jobs within build
pip$PYTHON install Sphinx>=1.1
make BUILDDIR=/root/docs -C /pyslurm/doc/ html

# Only push to GitHub Pages once per build
if [[ "$PYTHON" == "2.7" &&
"$CYTHON" == "0.27.3" &&
"$SLURM" == "17.11.8" &&
"$BRANCH" == "master" ]]
then
git clone https://github.com/pyslurm/pyslurm.github.io.git
rsync -av --delete --exclude=.git /root/docs/html/ /pyslurm.github.io/
cd pyslurm.github.io
git add .
git -c user.name="Travis" -c user.email="Travis" commit -m 'Updated docs'
git push -q https://giovtorres:$GITHUB_TOKEN@github.com/pyslurm/pyslurm.github.io &2>/dev/null
fi
pip install -r doc_requirements.txt
pip install --no-build-isolation -e .
mkdocs build
15 changes: 0 additions & 15 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
[aliases]
doc=build_sphinx
docs=build_sphinx

[bdist_rpm]
release = 1
packager = Giovanni Torres <giovtorres@users.noreply.github.com>
Expand All @@ -13,17 +9,6 @@ build_requires = python3-devel >= 3.6
requires = slurm
use_bzip2 = 1

[build_sphinx]
builder = man
source-dir = doc/source
build-dir = doc/build
all_files = 1

[options.extras_require]
docs = mkdocstrings[python]
mkdocs-material
mike

[flake8]
max-line-length = 88
extend-ignore = E203