So, iTerm recently landed support for the macOS Touch Bar (in that programs hosted in the terminal can create display-buttons for the touch bar that display custom content, and send a function-key such as F1..F12 to the terminal when tapped.)
The implementation uses iTerm2's 1337 escape-code with the SetKeyLabel, PushKeyLabels, and PopKeyLabels keys.
For instance, printing ESC+]1337;SetKeyLabel=F1=Save & Quit+BEL will cause iTerm2 to display a Touch Bar button with the text “Save & Quit”, that when tapped, sends
One example usage of this functionality is demonstrated here, where some of the cruft traditionally included in the command-line prompt is moved into the Touch Bar:

I'd love to see this support validated and duplicated by Hyper, given how cutting-edge Hyper tends to be in other ways.
We'd have to wait for Electron Touch Bar Support to get out of beta first ✌️
@henrikdahl Touch bar support in electron landed in v1.6.5
@wingrunr21
Note: The TouchBar API is currently experimental and may change or be removed in future Electron releases.
Not stable yet it appears ✌️
@henrikdahl
The note is there due to the newness of the Touch Bar itself, not due to the API. The API exists and is documented in a stable version of Electron.
Here's the relevant commit and explanation around that line: https://github.com/electron/electron/pull/8856
+1
@ELLIOTTCABLE I plan on looking into this soon (but maybe in the form of a plugin) when I can find some free time. Sad that this is a year old and appears to have no solution.
I just created a simple plugin for Hyper to add custom buttons to the touch bar. I hope you guys like it until the official support arrives.
Most helpful comment
@ELLIOTTCABLE I plan on looking into this soon (but maybe in the form of a plugin) when I can find some free time. Sad that this is a year old and appears to have no solution.