Skip to content

Commit

Permalink
allow retrieving doi code from rtd
Browse files Browse the repository at this point in the history
  • Loading branch information
OriolAbril committed Jan 10, 2022
1 parent f033fb2 commit fdf0e21
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions examples/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,16 +70,17 @@
],
}
version = os.environ.get("READTHEDOCS_VERSION", "")
version = version if "-" in version else "main"
version = version if "." in version else "main"
doi_code = os.environ.get("READTHEDOCS_DOI", "10.5281/zenodo.5654871")
html_context = {
"github_url": "https://github.com",
"github_user": "pymc-devs",
"github_repo": "pymc-examples",
"github_version": version,
"doc_path": "examples/",
"sandbox_repo": f"pymc-devs/pymc-sandbox/{version}",
"doi_url": "https://doi.org/10.5281/zenodo.5654871",
"doi_code": "10.5281/zenodo.5654871",
"doi_url": f"https://doi.org/{doi_code}",
"doi_code": doi_code,
}


Expand Down Expand Up @@ -122,6 +123,7 @@
"pip_dependencies": "{{ extra_dependencies }}",
"conda_dependencies": "{{ extra_dependencies }}",
"extra_install_notes": "",
"doi_code": doi_code,
}
jupyter_execute_notebooks = "off"

Expand Down

0 comments on commit fdf0e21

Please # to comment.