long term highlighting

Skip to first unread message

Max Waterman

Aug 1, 2022, 6:49:24 AMAug 1
to iterm2-discuss

I'm new to iterm2, so apologies if this is somehow obvious...

What I'm after is a way to highlight specific terms. I currently use the 'search' feature, which does the job, but I often find it grabs focus unexpectedly and I end up over-typing it. I also have multiple terms I'd like highlighted, eg:

'MAXMAXMAX' - I use this on my 'log' output when I'm trying to debug something
'Error' - when compiling
'errors generated.' - ditto

I'm sure there are others.
Ideally, I'd like to be able to set these to highlight all the time.
It'd be nice if I could also specify the colour of the highlight, so I could have a 'traffic light' system, whereby I would highlight 'warning' in amber, 'error' in red, etc etc.

Otherwise, I guess the features of the 'search' function are good to copy...ie a line on the scrollbar for each occurrance. I'm not sure about the need for the UI at the top though - that just seems to get in the way (and, as I mentioned, it seems like it grabs focus unexpectedly somehow - not sure how/why). Maybe it could be a 'dropdown' with all the search terms shown, defaulting to closed.

It seems like iterm2 is chock full of features, so I imagine this is already possible somehow, but it's not jumping out at me :)


Richard Mitchell

Aug 1, 2022, 7:33:12 AMAug 1
to iterm2-discuss
Have you looked at "Triggers" ?

Preferences -> Profiles -> Advanced -> Triggers

Here are some I currently have set:


Highlight Text and possibly Set Mark may be what you're looking for.

Max Waterman

Aug 1, 2022, 9:34:13 AMAug 1
to iterm2-discuss
Yes, that looks like it is exactly what I'm looking for....hrm, I'll have to check what 'Instant' means :)

Richard Mitchell

Aug 1, 2022, 9:58:01 AMAug 1
to iterm2-discuss
Must be a new (has in since I set mine up) option as I've never noticed it before.

I've never noticed a delay between the text appearing and the trigger.

Reply all
Reply to author
0 new messages