Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Fix ticket links in wiki conversion
  • Loading branch information
kwankyu committed Feb 6, 2023
commit 8a249487bb96444edd95ab395022c160d109bf4b
2 changes: 1 addition & 1 deletion migrate.cfg.example
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ url: https://example.com/xmlrpc
path: /path/to/trac/instance

# if no, a trac ticket reference is converted to the corresponding issue reference
keep_trac_ticket_references: yes
keep_trac_ticket_references: no

[issues]

Expand Down
2 changes: 1 addition & 1 deletion migrate.cfg.sagetracwikionly
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ url: https://trac.sagemath.org/xmlrpc
cgit_url: https://git.sagemath.org/sage.git/

# if no, a trac ticket reference is converted to the corresponding issue reference
keep_trac_ticket_references: yes
keep_trac_ticket_references: no

[issues]

Expand Down
2 changes: 1 addition & 1 deletion migrate.py
Original file line number Diff line number Diff line change
Expand Up @@ -1302,7 +1302,7 @@ def ticket_link(self, match):
if keep_trac_ticket_references:
return r'[#%s](%s/%s)' % (ticket, trac_url_ticket, ticket)
issue = ticket
return r'#%s' % ticket
return r'[#%s](%s/issues/%s)' % (issue, target_url_issues_repo, issue)

def ticket_comment_link(self, match):
"""
Expand Down