> On Oct 5, 2017, at 4:28 PM, Pete Siemsen <
sie...@ucar.edu> wrote:
>
> Thank you. Since I posted, I downloaded iTerm2 v3.1.2, and tried it.
> It looks like triggers does exactly what I want. Cool!
>
> Is there a mechanism to share a set of regular expressions? I'd like
> to have a set of regular expressions that make sense when connected to
> Cisco routers, and another for Juniper routers, etc. Of course, if
> someone has already done the work, in a way that I can load into
> iTerm, that would be great.
So, someone else will have to answer about sharing settings - I know there are various things people do, but I've paid little attention to that.
As far as sets of regex triggers, notice that you're building these in a profile. So you can set up a profile for Juniper, Cisco, etc. You can also automatically switch profiles based on some combination of host, path and user, but only if you have a shell on the remote machine that can run installable scripts. So that won't work on most network kit. (See Automatic Profile Switching, also on the same tab as Triggers.)
> The regular expression for matching an IPv6 address is not trivial :-)
Heh. Yeah, that gets a little gross at some point.
-j