/
githubmirror
/
lazygit
Обзор
Документация
Войти
/
githubmirror
/
lazygit
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
pkg/gui/style/hyperlink.go
13 строк
374 B
Stefan Haller
Add function to render a hyperlink
24 авг 2024, 11:36
24 авг 2024, 11:36
3f7674a
Код
Авторство
О чём код?
package style import "fmt" // Render the given text as an OSC 8 hyperlink func PrintHyperlink(text string, link string) string { return fmt.Sprintf("\033]8;;%s\033\\%s\033]8;;\033\\", link, text) } // Render a link where the text is the same as a link func PrintSimpleHyperlink(link string) string { return fmt.Sprintf("\033]8;;%s\033\\%s\033]8;;\033\\", link, link) }