diff options
author | Trey Hunner <treyhunner@gmail.com> | 2012-03-28 07:13:41 -0700 |
---|---|---|
committer | Trey Hunner <treyhunner@gmail.com> | 2012-03-28 07:14:22 -0700 |
commit | f85ead9356087cdf2f52526dbef25eaa4f1e8e38 (patch) | |
tree | 42ac0d4144c17f8d9c9785ae3abfa2bb70d98c44 | |
parent | 1b08a7f057c8d71edf7cb4523c32a8081e7ae55a (diff) | |
download | pycco-f85ead9356087cdf2f52526dbef25eaa4f1e8e38.tar.gz |
Use non-greedy regex matching for [[hyperlinks]]
-rw-r--r-- | pycco/main.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pycco/main.py b/pycco/main.py index 5817da4..8a3fba2 100644 --- a/pycco/main.py +++ b/pycco/main.py @@ -183,7 +183,7 @@ def preprocess(comment, section_nr, preserve_paths=True, outdir=None): } comment = re.sub('^([=]+)([^=]+)[=]*\s*$', replace_section_name, comment) - comment = re.sub('[^`]\[\[(.+)\]\]', replace_crossref, comment) + comment = re.sub('[^`]\[\[(.+?)\]\]', replace_crossref, comment) return comment |