README.md
1# Terminal Title
2
3Change the title if the currently running terminal emulator supports it.
4
5## Currently supported terminal emulators
6
7* `konsole`
8* `alacritty`
9* `gnome-terminal`
10
11For unsupported terminal emulators, the `MustSet` function will try the same terminal codes as for `gnome-terminal`.
12
13## Example use
14
15~~~go
16package main
17
18import (
19 "github.com/xyproto/termtitle"
20)
21
22func main() {
23 termtitle.Set("TESTING 1 2 3")
24}
25~~~
26
27## Terminal codes
28
29For `konsole` a working string seems to be:
30
31 \033]0;TITLE\a
32
33While for `gnome-terminal`, this one works:
34
35 \033]30;TITLE\007
36
37For `alacritty`, this seems to work:
38
39 \033]2;TITLE\007
40
41`TITLE` is the title that will be set.
42
43## General info
44
45* Version: 1.5.0
46* License: MIT
47