[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [stem/master] Truncating generated trac urls



commit d5ae78b127d1103927a6febb44587f62d1ed03d1
Author: Damian Johnson <atagar@xxxxxxxxxxxxxx>
Date:   Sun Apr 14 15:26:24 2013 -0700

    Truncating generated trac urls
    
    Trac expands short urls. For instance, when visited...
    
    https://trac.torproject.org/8596
    
    ... is expanded to...
    
    https://trac.torproject.org/projects/tor/ticket/8596
    
    I kinda prefer using the shortened version in our docs so copied links are more
    readable.
---
 docs/conf.py |    2 +-
 docs/trac.py |    4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/docs/conf.py b/docs/conf.py
index 7723736..5900035 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -224,4 +224,4 @@ man_pages = [
      ['%s (%s)' % (__author__, __contact__)], 1)
 ]
 
-trac_url = 'https://trac.torproject.org/projects/tor'
+trac_url = 'https://trac.torproject.org'
diff --git a/docs/trac.py b/docs/trac.py
index afc74e8..d2459dd 100644
--- a/docs/trac.py
+++ b/docs/trac.py
@@ -53,9 +53,9 @@ def make_link_node(rawtext, app, type, slug, options):
         raise ValueError('trac_url is not set (%s)' % str(e))
 
     slash = '/' if base[-1] != '/' else ''
-    ref = base + slash + type + '/' + slug
+    ref = base + slash + slug
     set_classes(options)
-    name = type + ' #' + unescape(slug)
+    name = type + ' ' + unescape(slug)
     node = reference(rawtext, name, refuri=ref, **options)
     return node
 



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits