mirror of
https://github.com/kovidgoyal/kitty
synced 2026-06-11 19:19:35 +02:00
Port recent changes from cli.py to Go
This commit is contained in:
@@ -273,7 +273,20 @@ func prettify(text string) string {
|
||||
case "env", "envvar":
|
||||
return ref_hyperlink(val, "envvar-")
|
||||
case "doc":
|
||||
text, target := text_and_target(val)
|
||||
if text == target {
|
||||
target = strings.Trim(target, "/")
|
||||
if title, ok := kitty.DocTitleMap[target]; ok {
|
||||
val = title + " <" + target + ">"
|
||||
}
|
||||
}
|
||||
return ref_hyperlink(val, "doc-")
|
||||
case "iss":
|
||||
return ref_hyperlink(val, "issues-")
|
||||
case "pull":
|
||||
return ref_hyperlink(val, "pull-")
|
||||
case "disc":
|
||||
return ref_hyperlink(val, "discussions-")
|
||||
case "ref":
|
||||
return ref_hyperlink(val, "")
|
||||
case "ac":
|
||||
|
||||
Reference in New Issue
Block a user