mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Remove env.need_refresh()
After the refactoring of the env object, it is not needed now. Note: It was appeared only on master branch. So deprecation process is not needed for this case.
This commit is contained in:
parent
157619c4e3
commit
987cd58252
@ -313,19 +313,6 @@ class BuildEnvironment(object):
|
||||
"""Like :meth:`warn`, but with source information taken from *node*."""
|
||||
self._warnfunc(msg, '%s:%s' % get_source_line(node), **kwargs)
|
||||
|
||||
def need_refresh(self, app):
|
||||
# type: (Sphinx) -> Tuple[bool, unicode]
|
||||
"""Check refresh environment is needed.
|
||||
|
||||
If needed, this method returns the reason for refresh.
|
||||
"""
|
||||
if self.version != app.registry.get_envversion(app):
|
||||
return True, __('build environment version not current')
|
||||
elif self.srcdir != app.srcdir:
|
||||
return True, __('source directory has changed')
|
||||
else:
|
||||
return False, None
|
||||
|
||||
def clear_doc(self, docname):
|
||||
# type: (unicode) -> None
|
||||
"""Remove all traces of a source file in the inventory."""
|
||||
|
Loading…
Reference in New Issue
Block a user