|
1 | 1 | # Synesthesia |
2 | | -### Sense your projects as iTerm2 tab colours |
| 2 | +### Sense your projects as terminal colours |
3 | 3 |
|
4 | | -Synesthesia updates your iTerm2 tab colours depending on the go module name in your directory ancestry. |
| 4 | +Synesthesia updates your terminal tab and background colours depending on the go module name in your directory ancestry. |
5 | 5 |
|
6 | | -Supports tinting the background with `--background-tint` and worktrees by default |
| 6 | +- **iTerm2**: Automatically updates the tab colour. |
| 7 | +- **Ghostty & Others**: Lightly tints the terminal background (enabled by default). |
| 8 | + |
| 9 | +If you use git worktrees (or jj workspaces), then each copy of the same project will have a different but consistent colour. |
7 | 10 |
|
8 | 11 | # Installation |
9 | 12 | ### 1. Install from source using golang 1.25 |
10 | 13 |
|
11 | | -``` |
| 14 | +```bash |
12 | 15 | go install github.com/roryq/synesthesia@latest |
13 | 16 | ``` |
14 | 17 |
|
15 | | -### 2. Then configure a hook for your shell. |
16 | | -### fish |
| 18 | +### 2. Configure a hook for your shell |
| 19 | + |
| 20 | +#### fish |
17 | 21 | Add the following line to your `~/.config/fish/config.fish`: |
18 | 22 | ```fish |
19 | | -synesthesia hook fish --background-tint | source |
| 23 | +synesthesia hook fish | source |
20 | 24 | ``` |
21 | 25 |
|
22 | | -### zsh |
23 | | -Add the following line to your `~/.zshrc` |
| 26 | +#### zsh |
| 27 | +Add the following line to your `~/.zshrc`: |
24 | 28 | ```zsh |
25 | | -eval "$(synesthesia hook zsh --background-tint)" |
| 29 | +eval "$(synesthesia hook zsh)" |
26 | 30 | ``` |
27 | 31 |
|
28 | 32 | # Usage |
29 | | -Navigate between your directories as usual. When you have multiple tabs open for different go projects, |
30 | | -a consistent random colour will be chosen for any tabs with the same go module name. |
| 33 | +Navigate between your directories as usual. When you have multiple tabs open for different projects, |
| 34 | +a consistent random colour will be chosen for any tabs with the same project name. |
31 | 35 |
|
32 | | -If you use git worktrees (or jj workspaces), then each copy of the same project will have a different but consistent colour. |
| 36 | +### Sense Custom Text |
| 37 | +You can sense a colour for any custom string (useful for agent names or specific project labels): |
| 38 | +```bash |
| 39 | +synesthesia sense "my-project-label" |
| 40 | +``` |
| 41 | + |
| 42 | +### Background Tinting |
| 43 | +Background tinting is enabled by default. To disable it, use the `--no-background-tint` flag: |
| 44 | +```bash |
| 45 | +synesthesia --no-background-tint |
| 46 | +``` |
| 47 | + |
| 48 | +To generate a hook with tinting disabled: |
| 49 | +```bash |
| 50 | +synesthesia hook zsh --no-background-tint |
| 51 | +``` |
33 | 52 |
|
34 | 53 |  |
35 | 54 |
|
|
0 commit comments