Screenshot instructions:
Windows
Mac
Red Hat Linux
Ubuntu
Click URL instructions:
Right-click on ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)
You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
|
Apr
(106) |
May
(215) |
Jun
(104) |
Jul
(290) |
Aug
(351) |
Sep
(245) |
Oct
(289) |
Nov
(184) |
Dec
(113) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(179) |
Feb
(88) |
Mar
(77) |
Apr
(70) |
May
(107) |
Jun
(288) |
Jul
(115) |
Aug
(67) |
Sep
(91) |
Oct
(34) |
Nov
(31) |
Dec
(61) |
2004 |
Jan
(54) |
Feb
(17) |
Mar
(102) |
Apr
(152) |
May
(178) |
Jun
(377) |
Jul
(136) |
Aug
(37) |
Sep
(196) |
Oct
(142) |
Nov
(119) |
Dec
(58) |
2005 |
Jan
(51) |
Feb
(76) |
Mar
(220) |
Apr
(132) |
May
(134) |
Jun
(230) |
Jul
(142) |
Aug
(58) |
Sep
(71) |
Oct
(76) |
Nov
(129) |
Dec
(117) |
2006 |
Jan
(94) |
Feb
(30) |
Mar
(97) |
Apr
(63) |
May
(63) |
Jun
(62) |
Jul
(23) |
Aug
(40) |
Sep
(47) |
Oct
(40) |
Nov
(23) |
Dec
(21) |
2007 |
Jan
(57) |
Feb
(65) |
Mar
(77) |
Apr
(23) |
May
(118) |
Jun
(127) |
Jul
(87) |
Aug
(33) |
Sep
(26) |
Oct
(8) |
Nov
(4) |
Dec
(25) |
2008 |
Jan
(16) |
Feb
(18) |
Mar
(16) |
Apr
(4) |
May
(22) |
Jun
(20) |
Jul
(38) |
Aug
(14) |
Sep
(18) |
Oct
(68) |
Nov
(16) |
Dec
(95) |
2009 |
Jan
(28) |
Feb
(16) |
Mar
(8) |
Apr
(44) |
May
(35) |
Jun
(41) |
Jul
(63) |
Aug
(40) |
Sep
(38) |
Oct
(41) |
Nov
(17) |
Dec
(9) |
2010 |
Jan
(9) |
Feb
(3) |
Mar
(71) |
Apr
(20) |
May
(15) |
Jun
(16) |
Jul
(33) |
Aug
(13) |
Sep
(39) |
Oct
(30) |
Nov
(25) |
Dec
(20) |
2011 |
Jan
(213) |
Feb
(252) |
Mar
(24) |
Apr
(24) |
May
(20) |
Jun
(21) |
Jul
(37) |
Aug
(18) |
Sep
(28) |
Oct
(65) |
Nov
(22) |
Dec
(48) |
2012 |
Jan
(35) |
Feb
(39) |
Mar
(17) |
Apr
(9) |
May
(37) |
Jun
(31) |
Jul
(23) |
Aug
(14) |
Sep
(16) |
Oct
(15) |
Nov
(5) |
Dec
(43) |
2013 |
Jan
(15) |
Feb
(19) |
Mar
(26) |
Apr
(13) |
May
(9) |
Jun
(11) |
Jul
(32) |
Aug
(9) |
Sep
(6) |
Oct
|
Nov
(13) |
Dec
(5) |
2014 |
Jan
(2) |
Feb
(3) |
Mar
(1) |
Apr
|
May
(2) |
Jun
(4) |
Jul
(18) |
Aug
|
Sep
|
Oct
(3) |
Nov
(4) |
Dec
(2) |
2015 |
Jan
(3) |
Feb
(25) |
Mar
(49) |
Apr
(28) |
May
(13) |
Jun
(2) |
Jul
(2) |
Aug
(14) |
Sep
(9) |
Oct
(6) |
Nov
|
Dec
(2) |
2016 |
Jan
(2) |
Feb
(1) |
Mar
|
Apr
|
May
(12) |
Jun
|
Jul
(17) |
Aug
(7) |
Sep
(3) |
Oct
(2) |
Nov
(5) |
Dec
(28) |
2017 |
Jan
(11) |
Feb
(6) |
Mar
(10) |
Apr
(10) |
May
(34) |
Jun
(32) |
Jul
(15) |
Aug
(28) |
Sep
(8) |
Oct
(10) |
Nov
(14) |
Dec
(2) |
2018 |
Jan
(8) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
|
|
|
|
1
|
2
|
3
|
4
|
5
|
6
|
7
|
8
|
9
|
10
|
11
|
12
(3) |
13
(1) |
14
|
15
|
16
(5) |
17
(1) |
18
(2) |
19
|
20
(2) |
21
(5) |
22
|
23
|
24
|
25
|
26
|
27
|
28
|
|
|
From: <milde@us...> - 2013-02-18 21:22:29
|
Revision: 7610 http://docutils.svn.sourceforge.net/docutils/?rev=7610&view=rev Author: milde Date: 2013-02-18 21:22:20 +0000 (Mon, 18 Feb 2013) Log Message: ----------- Support embedded aliases within hyperlink references. Modified Paths: -------------- trunk/docutils/HISTORY.txt trunk/docutils/docs/ref/rst/restructuredtext.txt trunk/docutils/docutils/parsers/rst/states.py trunk/docutils/test/test_parsers/test_rst/test_inline_markup.py trunk/docutils/test/test_transforms/test_hyperlinks.py Modified: trunk/docutils/HISTORY.txt =================================================================== --- trunk/docutils/HISTORY.txt 2013-02-18 20:45:21 UTC (rev 7609) +++ trunk/docutils/HISTORY.txt 2013-02-18 21:22:20 UTC (rev 7610) @@ -19,6 +19,7 @@ * General - Apply [ 2714873 ] Fix for the overwritting of document attributes. + - Support embedded aliases within hyperlink references. * docutils/nodes.py Modified: trunk/docutils/docs/ref/rst/restructuredtext.txt =================================================================== --- trunk/docutils/docs/ref/rst/restructuredtext.txt 2013-02-18 20:45:21 UTC (rev 7609) +++ trunk/docutils/docs/ref/rst/restructuredtext.txt 2013-02-18 21:22:20 UTC (rev 7610) @@ -1862,7 +1862,8 @@ .. _link: underscore\_ It is possible (although not generally recommended) to include URIs - directly within hyperlink references. See `Embedded URIs`_ below. + directly within hyperlink references. See `Embedded URIs and Aliases`_ + below. 3. _`Indirect hyperlink targets` have a hyperlink reference in their link blocks. In the following example, target "one" indirectly @@ -1891,6 +1892,9 @@ .. _split: `A Hyperlink`_ + It is possible to include an alias directly within hyperlink + references. See `Embedded URIs and Aliases`_ below. + If the reference name contains any colons, either: - the phrase must be enclosed in backquotes:: @@ -2649,24 +2653,30 @@ hyperlinks. -Embedded URIs -````````````` +Embedded URIs and Aliases +````````````````````````` -A hyperlink reference may directly embed a target URI inline, within -angle brackets ("<...>") as follows:: +A hyperlink reference may directly embed a target URI or a hyperlink +reference within angle brackets ("<...>") as follows:: See the `Python home page <http://www.python.org>`_ for info. + This `link <Python home page_>`_ is an alias to the link above. + This is exactly equivalent to:: See the `Python home page`_ for info. + This link_ is an alias to the link above. + .. _Python home page: http://www.python.org + .. _link: `Python home page`_ The bracketed URI must be preceded by whitespace and be the last text -before the end string. With a single trailing underscore, the -reference is named and the same target URI may be referred to again. +before the end string. +With a single trailing underscore, the reference is named and the same +target URI may be referred to again. With two trailing underscores, the reference and target are both anonymous, and the target cannot be referred to again. These are "one-off" hyperlinks. For example:: @@ -2682,10 +2692,19 @@ __ http://www.rfc-editor.org/rfc/rfc2396.txt __ http://www.rfc-editor.org/rfc/rfc2732.txt -If reference text happens to end with angle-bracketed text that is -*not* a URI, the open-angle-bracket needs to be backslash-escaped. -For example, here is a reference to a title describing a tag:: +If a target URI happens to end with an underscore, this needs to be +backslash-escaped to avoid being parsed as hyperlink reference. For +example :: + Use the `source <parrots.txt\_>`__. + +creates an anonymous reference to the file ``parrots.txt_``. + +If the reference text happens to end with angle-bracketed text that is +*not* a URI or hyperlink reference, the open-angle-bracket needs to be +backslash-escaped. For example, here is a reference to a title +describing a tag:: + See `HTML Element: \<a>`_ below. The reference text may also be omitted, in which case the URI will be Modified: trunk/docutils/docutils/parsers/rst/states.py =================================================================== --- trunk/docutils/docutils/parsers/rst/states.py 2013-02-18 20:45:21 UTC (rev 7609) +++ trunk/docutils/docutils/parsers/rst/states.py 2013-02-18 21:22:20 UTC (rev 7610) @@ -608,13 +608,14 @@ ) %(end_string_suffix)s """ % locals(), re.VERBOSE | re.UNICODE), - embedded_uri=re.compile( + embedded_link=re.compile( r""" ( (?:[ \n]+|^) # spaces or beginning of line/string < # open bracket %(non_whitespace_after)s - ([^<>\x00]+) # anything but angle brackets & nulls + ([^<>\x00]+(\x00_)?) # anything but angle brackets & nulls + # except escaped trailing low line %(non_whitespace_before)s > # close bracket w/o whitespace before ) @@ -787,41 +788,63 @@ return string[:matchstart], [prb], string[matchend:], [msg] def phrase_ref(self, before, after, rawsource, escaped, text): - match = self.patterns.embedded_uri.search(escaped) - if match: + match = self.patterns.embedded_link.search(escaped) + if match: # embedded <URI> or <alias_> text = unescape(escaped[:match.start(0)]) - uri_text = match.group(2) - uri = ''.join(uri_text.split()) - uri = self.adjust_uri(uri) - if uri: - target = nodes.target(match.group(1), refuri=uri) + aliastext = unescape(match.group(2), restore_backslashes=True) + if aliastext.endswith('_') and not aliastext.endswith(r'\_'): + aliastype = 'name' + alias = normalize_name(aliastext[:-1]) + target = nodes.target(match.group(1), refname=alias) + target.indirect_reference_name = aliastext[:-1] + else: + aliastype = 'uri' + alias = ''.join(aliastext.split()) + alias = self.adjust_uri(alias) + if alias.endswith(r'\_'): + alias = alias[:-2] + '_' + target = nodes.target(match.group(1), refuri=alias) target.referenced = 1 - else: - raise ApplicationError('problem with URI: %r' % uri_text) + if not aliastext: + raise ApplicationError('problem with embedded link: %r' + % aliastext) if not text: - text = uri + text = alias else: target = None + refname = normalize_name(text) reference = nodes.reference(rawsource, text, name=whitespace_normalize_name(text)) node_list = [reference] + if rawsource[-2:] == '__': - if target: - reference['refuri'] = uri + if target and (aliastype == 'name'): + reference['refname'] = alias + self.document.note_refname(reference) + # self.document.note_indirect_target(target) # required? + elif target and (aliastype == 'uri'): + reference['refuri'] = alias else: reference['anonymous'] = 1 else: if target: - reference['refuri'] = uri target['names'].append(refname) - self.document.note_explicit_target(target, self.parent) + if aliastype == 'name': + reference['refname'] = alias + self.document.note_indirect_target(target) + self.document.note_refname(reference) + else: + reference['refuri'] = alias + self.document.note_explicit_target(target, self.parent) + # target.note_referenced_by(name=refname) node_list.append(target) else: reference['refname'] = refname self.document.note_refname(reference) return before, node_list, after, [] + def adjust_uri(self, uri): match = self.patterns.email.match(uri) if match: Modified: trunk/docutils/test/test_parsers/test_rst/test_inline_markup.py =================================================================== --- trunk/docutils/test/test_parsers/test_rst/test_inline_markup.py 2013-02-18 20:45:21 UTC (rev 7609) +++ trunk/docutils/test/test_parsers/test_rst/test_inline_markup.py 2013-02-18 21:22:20 UTC (rev 7610) @@ -1037,8 +1037,93 @@ <reference name="anonymous" refuri="anonymous"> anonymous """], +["""\ +Escape trailing low-line char in URIs: + +`<reference\_>`_ + +`<anonymous\_>`__ +""", +"""\ +<document source="test data"> + <paragraph> + Escape trailing low-line char in URIs: + <paragraph> + <reference name="reference_" refuri="reference_"> + reference_ + <target ids="reference" names="reference_" refuri="reference_"> + <paragraph> + <reference name="anonymous_" refuri="anonymous_"> + anonymous_ +"""], ] +totest['embedded_aliases'] = [ +["""\ +`phrase reference <alias_>`_ +""", +"""\ +<document source="test data"> + <paragraph> + <reference name="phrase reference" refname="alias"> + phrase reference + <target names="phrase\ reference" refname="alias"> +"""], +["""\ +`anonymous reference <alias_>`__ +""", +"""\ +<document source="test data"> + <paragraph> + <reference name="anonymous reference" refname="alias"> + anonymous reference +"""], +["""\ +`embedded alias on next line +<alias_>`__ +""", +"""\ +<document source="test data"> + <paragraph> + <reference name="embedded alias on next line" refname="alias"> + embedded alias on next line +"""], +["""\ +`embedded alias across lines <alias +phrase_>`__ +""", +"""\ +<document source="test data"> + <paragraph> + <reference name="embedded alias across lines" refname="alias phrase"> + embedded alias across lines +"""], +["""\ +`embedded alias with whitespace <alias +long phrase_>`__ +""", +"""\ +<document source="test data"> + <paragraph> + <reference name="embedded alias with whitespace" refname="alias long phrase"> + embedded alias with whitespace +"""], +[r""" +`embedded alias with too much whitespace < alias_ >`__ + +`embedded alias with no preceding whitespace<alias_>`__ +""", +"""\ +<document source="test data"> + <paragraph> + <reference anonymous="1" name="embedded alias with too much whitespace < alias_ >"> + embedded alias with too much whitespace < alias_ > + <paragraph> + <reference anonymous="1" name="embedded alias with no preceding whitespace<alias_>"> + embedded alias with no preceding whitespace<alias_> +"""], +] + totest['inline_targets'] = [ ["""\ _`target` Modified: trunk/docutils/test/test_transforms/test_hyperlinks.py =================================================================== --- trunk/docutils/test/test_transforms/test_hyperlinks.py 2013-02-18 20:45:21 UTC (rev 7609) +++ trunk/docutils/test/test_transforms/test_hyperlinks.py 2013-02-18 21:22:20 UTC (rev 7610) @@ -339,6 +339,42 @@ . """], ["""\ +An `embedded alias <alias_>`_. + +Another reference to the same `embedded alias`_. + +.. _alias: ham.py +""", +"""\ +<document source="test data"> + <paragraph> + An \n\ + <reference name="embedded alias" refuri="ham.py"> + embedded alias + <target names="embedded\ alias" refuri="ham.py"> + . + <paragraph> + Another reference to the same \n\ + <reference name="embedded alias" refuri="ham.py"> + embedded alias + . + <target ids="alias" names="alias" refuri="ham.py"> +"""], +["""\ +An `anonymous embedded alias <redirect_>`__. + +.. _redirect: spam.py +""", +"""\ +<document source="test data"> + <paragraph> + An \n\ + <reference name="anonymous embedded alias" refuri="spam.py"> + anonymous embedded alias + . + <target ids="redirect" names="redirect" refuri="spam.py"> +"""], +["""\ .. _target: .. [1] Footnote; target_ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <grubert@us...> - 2013-02-18 20:45:29
|
Revision: 7609 http://docutils.svn.sourceforge.net/docutils/?rev=7609&view=rev Author: grubert Date: 2013-02-18 20:45:21 +0000 (Mon, 18 Feb 2013) Log Message: ----------- Fix functional manpage test Modified Paths: -------------- trunk/docutils/test/functional/expected/standalone_rst_manpage.man Modified: trunk/docutils/test/functional/expected/standalone_rst_manpage.man =================================================================== --- trunk/docutils/test/functional/expected/standalone_rst_manpage.man 2013-02-17 23:14:21 UTC (rev 7608) +++ trunk/docutils/test/functional/expected/standalone_rst_manpage.man 2013-02-18 20:45:21 UTC (rev 7609) @@ -67,10 +67,10 @@ .BI \-\-config\fB= <file> Read configuration settings from <file>, if it exists. .TP -.B \-\-version, \-V +.B \-\-version\fP,\fB \-V Show this program\(aqs version number and exit. .TP -.B \-\-help, \-h +.B \-\-help\fP,\fB \-h Show this help message and exit. .UNINDENT .sp This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |