mirror of
https://github.com/scrapy/scrapy.git
synced 2025-02-23 21:04:20 +00:00
added issue role to documentation
This commit is contained in:
parent
3891c20840
commit
7c8af83138
@ -24,6 +24,7 @@ def setup(app):
|
|||||||
)
|
)
|
||||||
app.add_role('source', source_role)
|
app.add_role('source', source_role)
|
||||||
app.add_role('commit', commit_role)
|
app.add_role('commit', commit_role)
|
||||||
|
app.add_role('issue', issue_role)
|
||||||
app.add_role('rev', rev_role)
|
app.add_role('rev', rev_role)
|
||||||
|
|
||||||
def source_role(name, rawtext, text, lineno, inliner, options={}, content=[]):
|
def source_role(name, rawtext, text, lineno, inliner, options={}, content=[]):
|
||||||
@ -32,6 +33,12 @@ def source_role(name, rawtext, text, lineno, inliner, options={}, content=[]):
|
|||||||
node = nodes.reference(rawtext, text, refuri=ref, **options)
|
node = nodes.reference(rawtext, text, refuri=ref, **options)
|
||||||
return [node], []
|
return [node], []
|
||||||
|
|
||||||
|
def issue_role(name, rawtext, text, lineno, inliner, options={}, content=[]):
|
||||||
|
ref = 'https://github.com/scrapy/scrapy/issues/' + text
|
||||||
|
set_classes(options)
|
||||||
|
node = nodes.reference(rawtext, 'issue ' + text, refuri=ref, **options)
|
||||||
|
return [node], []
|
||||||
|
|
||||||
def commit_role(name, rawtext, text, lineno, inliner, options={}, content=[]):
|
def commit_role(name, rawtext, text, lineno, inliner, options={}, content=[]):
|
||||||
ref = 'https://github.com/scrapy/scrapy/commit/' + text
|
ref = 'https://github.com/scrapy/scrapy/commit/' + text
|
||||||
set_classes(options)
|
set_classes(options)
|
||||||
|
@ -6,7 +6,6 @@ Release notes
|
|||||||
|
|
||||||
Scrapy changes:
|
Scrapy changes:
|
||||||
|
|
||||||
- changed LogFormatter API to support lazy formatting of scraped/dropped items. #164 (:commit:`dcef7b0`)
|
|
||||||
- added :meth:`~scrapy.contrib.spidermiddleware.SpiderMiddleware.process_start_requests` method to spider middlewares
|
- added :meth:`~scrapy.contrib.spidermiddleware.SpiderMiddleware.process_start_requests` method to spider middlewares
|
||||||
- dropped Signals singleton. Signals should now be accesed through the Crawler.signals attribute. See the signals documentation for more info.
|
- dropped Signals singleton. Signals should now be accesed through the Crawler.signals attribute. See the signals documentation for more info.
|
||||||
- dropped Signals singleton. Signals should now be accesed through the Crawler.signals attribute. See the signals documentation for more info.
|
- dropped Signals singleton. Signals should now be accesed through the Crawler.signals attribute. See the signals documentation for more info.
|
||||||
@ -30,6 +29,7 @@ Scrapy changes:
|
|||||||
- ``DOWNLOAD_TIMEOUT`` spider attribute will no longer work, use ``download_timeout`` attribute instead
|
- ``DOWNLOAD_TIMEOUT`` spider attribute will no longer work, use ``download_timeout`` attribute instead
|
||||||
- removed ``ENCODING_ALIASES`` setting, as encoding auto-detection has been moved to the `w3lib`_ library
|
- removed ``ENCODING_ALIASES`` setting, as encoding auto-detection has been moved to the `w3lib`_ library
|
||||||
- promoted :ref:`topics-djangoitem` to main contrib
|
- promoted :ref:`topics-djangoitem` to main contrib
|
||||||
|
- LogFormatter method now return dicts(instead of strings) to support lazy formatting (:issue:`164`, :commit:`dcef7b0`)
|
||||||
|
|
||||||
Scrapyd changes:
|
Scrapyd changes:
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user