sample-code: link-the-docs using Modern™️ terminal escape sequences
This commit is contained in:
parent
4a2cd9303e
commit
722036dfbb
9
sample-code/link-the-docs.cl
Executable file
9
sample-code/link-the-docs.cl
Executable file
@ -0,0 +1,9 @@
|
|||||||
|
#!/usr/bin/env -S conlang -r false
|
||||||
|
|
||||||
|
fn link (link, text) -> &str
|
||||||
|
"\x1b]8;;" + link + "\x1b\\" + text + "\x1b]8;;\x1b\\";
|
||||||
|
|
||||||
|
fn main () {
|
||||||
|
println(link("https://conlang.foo/docs", "Here's a link to the docs!"));
|
||||||
|
println(link("https://conlang.foo/source", "Here's a link to the source!"))
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user