Skip to content

DOC: add Sphinx roles for DOI and arXiv links #6650

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 6 commits into from
Oct 3, 2016
Merged

Conversation

ev-br
Copy link
Member

@ev-br ev-br commented Oct 2, 2016

This way, correct hyperlinks are generated automagically in the docstrings.

@ev-br ev-br added the maintenance Items related to regular maintenance tasks label Oct 2, 2016
@larsoner
Copy link
Member

larsoner commented Oct 2, 2016

Could this be put in numpydoc instead so that other projects can more easily make use of it?

@pv
Copy link
Member

pv commented Oct 2, 2016

I think inclusion in numpydoc can be considered as a separate issue.

@ev-br
Copy link
Member Author

ev-br commented Oct 2, 2016

My reading of numpy/numpydoc#34 is that it's not wanted in numpydoc. I'm happy to redirect it otherwise.

@larsoner
Copy link
Member

larsoner commented Oct 2, 2016

Yeah I agree after reading that issue

@rgommers
Copy link
Member

rgommers commented Oct 3, 2016

Looks fine to me to add this, quite small and makes the docs more uniform.

Can you add a link to where you found this code? A search for doi_role or doilinks doesn't lead me to the right place.

@ev-br
Copy link
Member Author

ev-br commented Oct 3, 2016

It's from https://gist.github.com/jonls/b910afc46473b02597c4
The link was hiding in the commit message, and numpy/numpydoc#34 (comment)

One search line which finds it is "DOI role Sphinx".

For completeness, I'll note that networkx has something similar, https://github.com/networkx/networkx/blob/master/doc/sphinxext/customroles.py

@rgommers
Copy link
Member

rgommers commented Oct 3, 2016

Thanks, LGTM.

@larsoner
Copy link
Member

larsoner commented Oct 3, 2016

LGTM +1 for merge

@pv pv merged commit 082325f into scipy:master Oct 3, 2016
@pv pv added this to the 0.19.0 milestone Oct 3, 2016
@ev-br ev-br deleted the doi_role branch October 3, 2016 20:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Items related to regular maintenance tasks
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants