Skip to content
Snippets Groups Projects
Commit 4bdd6c7b authored by Vincent Hatakeyama's avatar Vincent Hatakeyama
Browse files

conf2reST.py: try to use links for versions

parent 71f6fb39
No related branches found
No related tags found
No related merge requests found
...@@ -188,7 +188,25 @@ ...@@ -188,7 +188,25 @@
out.write(" - version\n") out.write(" - version\n")
for element in rst[group].keys(): for element in rst[group].keys():
out.write(" * - %s\n" % element) out.write(" * - %s\n" % element)
out.write(" - %s\n" % rst[group][element]['version']) version = rst[group][element]['version']
repository =
if repository.startswith('ssh://hg@bitbucket.org/')
text = '`%s <%s/commits/%s>`_' {
version,
repository.replace(
'ssh://hg@bitbucket.org/',
'https://bitbucket.org/'),
version)
elif repository.startswith('git@bitbucket.org:'):
text = '`%s <%s/commits/%s>`_' {
version,
repository.replace(
'git@bitbucket.org:',
'https://bitbucket.org/').replace('.git', ''),
version)
else:
text = version
out.write(" - %s\n" % text)
out.write("\n") out.write("\n")
if __name__ == '__main__': if __name__ == '__main__':
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment