3 ms·
Does anyone know if the inline images/videos are implemented as terminal escapes. I.e. can you find | xargs tycat | less and scroll around with the data?
by onedognight 14y ago
Does anyone know if the inline images/videos are implemented as terminal escapes. I.e. can you
find | xargs tycat | less
and scroll around with the data? Can it work remotely?
- billiob 14y agoIt's done using escape codes (\033}). tycat/tyls/ty* only outputs escape codes. Terminology handles them and display the images… In tycat.c, you can see some code like: if (mode == CENTER) snprintf(buf, sizeof(buf), "%c}ic#%i;%i;%s", 0x1b, w, h, path); Because the path is given, it won't work remotely. find | xargs tycat should work but doesn't (one more bug to fix :D ).
- onedognight 14y agoGiven that you can communicate two ways with terminals using escape codes, you might be able to run your remote shell with something like tyserver bash and tyserver could then say replace escape-w-h-path with an escape-w-h-file-descriptor-n which would then allow the remote side to async query for the contents of fd-n with an escape-read-fd-n-bytes while you continue to interact with the terminal.