change to missing_reference

This commit is contained in:
Nabil Freij 2018-10-28 15:05:59 +00:00
parent 81dcf73eb0
commit ff8ea0699d
5 changed files with 42 additions and 34 deletions

View file

@ -50,7 +50,7 @@ jobs:
- run: *docs-install
- run: python setup.py build_sphinx
- store_artifacts:
path: build/sphinx/html/index.html
path: build/sphinx/html/
- run:
name: "Built documentation is available at:"

View file

@ -5,8 +5,12 @@ ABlog for Sphinx
:target: https://travis-ci.org/sunpy/ablog
.. image:: https://circleci.com/gh/sunpy/ablog.svg?style=svg
:target: https://circleci.com/gh/sunpy/ablog
.. image:: https://ci.appveyor.com/api/projects/status/cmmiadqoy5lx7l78?svg=true)
:target: https://ci.appveyor.com/project/sunpy/ablog
**Please note that is an official continuation of** `Ahmet Bakan's Ablog Sphinx extension <https://github.com/abakan/ablog/>`_.
** Please note that is an official new home of** `Ahmet Bakan's Ablog Sphinx extension <https://github.com/abakan/ablog/>`_.
** This version is maintined and tested with various verisons of Python and Sphinx. **
** New features are unlikely. **
ABlog is a Sphinx extension that converts any documentation or personal website project into a full-fledged blog with:

View file

@ -456,8 +456,8 @@ def process_postlist(app, doctree, docname):
def missing_reference(app, env, node, contnode):
target = node['reftarget']
return _missing_reference(app, target, node['refdoc'],
contnode, node['refexplicit'])
return _missing_reference(app, target, node.get('refdoc'),
contnode, node.get('refexplicit'))
def _missing_reference(app, target, refdoc, contnode=None, refexplicit=False):

View file

@ -1,24 +1,25 @@
# AppVeyor.com is a Continuous Integration service to build and run tests under
# Windows
# AppVeyor.com is a Continuous Integration service to build and run tests under Windows
environment:
global:
PYTHON: "C:\\conda"
MINICONDA_VERSION: "latest"
# SDK v7.0 MSVC Express 2008's SetEnv.cmd script will fail if the
# /E:ON and /V:ON options are not enabled in the batch script intepreter
# See: http://stackoverflow.com/a/13751649/163740
CMD_IN_ENV: "cmd /E:ON /V:ON /C .\\ci-helpers\\appveyor\\windows_sdk.cmd"
CONDA_CHANNELS: "conda-forge"
CONDA_DEPENDENCIES: "sphinx werkzeug alabaster invoke graphviz nbsphinx"
PIP_DEPENDENCIES: "sphinx-automodapi"
global:
PYTHON: "C:\\conda"
MINICONDA_VERSION: "latest"
CMD_IN_ENV: "cmd /E:ON /V:ON /C .\\ci-helpers\\appveyor\\windows_sdk.cmd"
PYTHON_ARCH: "64" # needs to be set for CMD_IN_ENV to succeed. If a mix
# of 32 bit and 64 bit builds are needed, move this
# to the matrix section.
CONDA_CHANNELS: "conda-forge"
CONDA_DEPENDENCIES: "sphinx werkzeug alabaster invoke graphviz nbsphinx"
PIP_DEPENDENCIES: "sphinx-automodapi"
matrix:
- PYTHON_VERSION: "2.7"
- PYTHON_VERSION: "3.5"
- PYTHON_VERSION: "3.6"
- PYTHON_VERSION: "3.7"
matrix:
- PYTHON_VERSION: "2.7"
- PYTHON_VERSION: "3.5"
- PYTHON_VERSION: "3.6"
- PYTHON_VERSION: "3.7"
build: false
matrix:
fast_finish: true
@ -26,22 +27,24 @@ matrix:
platform:
- x64
before_test:
- cinst pandoc
- cinst graphviz
- set PATH="%PATH%;C:\Program Files (x86)\Pandoc\"
os: Visual Studio 2017
install:
- "git clone git://github.com/astropy/ci-helpers.git"
- "powershell ci-helpers/appveyor/install-miniconda.ps1"
- "SET PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%"
- "activate test"
- "pip install -e ."
- ps: >-
if (-Not (Test-Path "C:\Program Files\Pandoc\")) {
cinst pandoc --no-progress
cinst graphviz --no-progress
}
- ps: $env:Path += ";C:\Program Files\Pandoc\"
- git clone git://github.com/astropy/ci-helpers.git
- powershell ci-helpers/appveyor/install-miniconda.ps1
- SET PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%
- activate test
- pip install -e .
# Not a .NET project, we build Ablog in the install step instead
build: false
test_script:
- python setup.py build_sphinx
- ps: cd docs
- ablog build -T
- ablog build -b latex -T -d .doctrees -w _latex

View file

@ -52,8 +52,9 @@ setup(
'Programming Language :: Python :: 3',
],
provides=['ablog'],
install_requires=['werkzeug', 'sphinx>=1.6', 'alabaster', 'invoke', 'python-dateutil', 'sphinx-automodapi'],
extra_requires=['nbsphinx'],
install_requires=['werkzeug', 'sphinx>=1.6', 'alabaster', 'invoke',
'python-dateutil', 'sphinx-automodapi'],
extra_requires={'notebook': ['nbsphinx', 'ipython']},
message_extractors={
'ablog': [
('**.html', 'jinja2', None),