linkify_github_refs

docblock
linkify_github_refs(text::String, repo::String) -> String

Convert GitHub references in text to clickable links.

Converts:

  • #123 -> [#123](https://github.com/repo/issues/123)
  • @username -> [@username](https://github.com/username)
  • user/repo#123 -> [user/repo#123](https://github.com/user/repo/issues/123)

Arguments

  • text::String: Text containing references
  • repo::String: Repository in “user/repo” format

Returns

Text with references converted to markdown links.

Example

text = "Fixed bug #42 reported by @user"
linkify_github_refs(text, "myorg/mypackage")
# "Fixed bug [#42](https://github.com/myorg/mypackage/issues/42) reported by [@user](https://github.com/user)"