I'm working on what is effectively a fork of prompt_toolkit [1], which supports many modern terminal features I needed for euporie [2], such as terminal graphics, extra text styles, color palette detection, terminal clipboard, synchronized outputs, CSI-u, mouse pixel positioning, etc.
I'd be very interested to test it's performance and to read your code (I'm not an AI, promise :)
It's very interesting to learn about the newly proposed glyph protocol [1] in the linked blog post.
I was bemoaning the lack of exactly this here about 6 months ago [2]!
The idea that every application should ship their own glyphs because some proprietary systems do not have normal fonts, is not great. Fix the terminal instead.
Also, if you want advanced GUI with icons, maybe you should just write a GUI app.
As for shipping custom icons, this is not very bright idea as well. If you switch between several applications on one terminal, then one application can redefine glyphs from another application. Also, when the application terminates, nobody cleans up its glyphs. Also, this increases attack surface because font standards are pretty complicated and one will be able to attack the system by just providing a glyph. We already have programs that can break the terminal, which should never happen.
Also, as for icons, I find emoji characters too distracting (and too large). They stand out too much and take away user's attention, breaking any visual hierarchy. The icons in terminal should be monochrome, and with thin lines, so that they do not distract you from the text and its structure.
I'm specifically interested in querying for support of particular glyphs (e.g. the symbols for legacy computing block), so applications can use a different fallback if it is know that a particular glyph cannot be rendered and will break the interface.
I agree that the addition of sending custom glyphs to the terminal is potentially problematic.
I think this is not an application responsibility. Do you also check which Wayland extensions the system has, and install your own if some are missing?
Oh hey, that's a nice idea! Unlike some of the terminal projects I've seen recently, it addresses a problem without entirely reinventing the idea of what terminals can do.
No evolution necessary! With my project, euporie [1], you can have use your data science notebooks with graphical image outputs, HTML, LaTeX, etc, all in the terminal.
This is such an amazing project. I find it so awesome that I can bump on such projects (and their creators, Hi!) on hackernews.
I wish to ask a question if I may (and as such pardon my ignorance on jupyter kernel, I don't know much about it and I hope you can tell me more about it :-D)
but my question is, is there a way to swap the jupyter kernel within euphorie to something else more minimalist?
And when you run a project with ssh, there are ways to give access to other users with user:password if I may ask?
I didn't know that there were ways to run jupyter kernels in terminal, I don't know when I might need it but I am prepared with this information now, this feels so nice to me, thanks for making it!!
This is like a checklist of a thing I didn't know that I needed/existed but the second I know that it has existed, it feels like my mind has checked it off and just a satisfaction from knowing projects like these existing.
(I think in some sense this is a bit of same reaction to me on Ratty too), Its just so good seeing projects in these spaces :-D
Edit: just remembered the one time I think I was using some websites which gave me jupyter and then I tried to use browsh to run jupyter to run jupyter in terminal so that it can be controlled by terminal but it had some issues and I wasn't able to run it.
I also wish to ask if there is a way to sign in to jupyter instance like that itself perhaps? (IIRC it was a jupyterhub instance)
> is there a way to swap the jupyter kernel within euphorie to something else more minimalist?
You can use euporie-console for a REPL-like terminal experience (still with rich outputs) if you don't want the full notebook experience.
You can also select the `local-python` kernel in euporie to run code using the local Python interpretor which runs euporie, instead of connecting to a Jupyter kernel.
> And when you run a project with ssh, there are ways to give access to other users with user:password if I may ask?
> I also wish to ask if there is a way to sign in to jupyter instance like that itself perhaps?
euporie-hub supports spawning notebook instances for connected users, but I haven't implemented collaborative editing like JupyterLab supports (yet). I believe that jpterm [1] might support this.
that looks awesome (btw: a demo video would be nice, i could not find any), but it's not solving the problem terminals are generally used for.
i want something like jupyter but for unix shells, not for programming languages. and, i don't want it in the terminal, i want it to be the terminal, that is, i want to get rid of terminal escape codes that you currently need to make this work.
think about it like this: in jupyter you have pieces of code and their output. you change the code, it changes the output.
a unix shell version of this would be a commandline, and its output which would be text or an image or whatever the commandline produced. every output box would be itself a terminal if the output is text. but that's only necessary to support programs that produce terminal output. new programs could produce structured data that this jupyter for shells could interpret and display directly.
You mention using this over ssh. Is there any way to get this working in tmux or anything similar by any chance? Or is the idea that euporie itself is acting like a multiplexer?
This sounds like an ideal use case for modshim [0]
One of its intended use cases is bridging contribution gaps: while contributing upstream is ideal, maintainers may be slow to merge contributions for various reasons. Forking in response creates a permanent schism and a significant maintenance burden for what might be a small change. Modshim would allow you to create a new Python package containing only the fixes for your bugbears, while automatically inheriting the rest from upstream httpx.
Since modshim isn't money patching and appears to only be wrapping the external API of a package, if the change is deep enough inside the package, wouldn't you end up reimplementing most of the package from the outside?
Modshim does more than just wrap the external API of a package - it allows you to tweak something internal to the module while leaving its interface alone, without having to re-implement most of the package in order to re-bind new versions of objects.
There are a couple of example of this readme: (1) modifing the TextWrapper object but then use it through the textwrap library's wrap() function, and (2) modifing the requests Session object, but then just using the standard requests.get(). Without modshim (using standard monkey-patching) you would have to re-implement the wrap and get methods in order to bind the new TextWrapper / Session classes.
One of the really cool things about chafa is that it has both sixel and kitty graphic renderers! (and iterm2 images as well) So you can output kitty if the terminal supports it, but fall back to ascii if it doesn’t.
What interests me about it is the unicode mosaic output format that looks higher quality than the usual upper half block or braille character approaches without needing to support a special protocol.
Setting aside the usual compatibility issues with those things.. neither are available from your buildbot. Also while Jupyter does supports images other notebooking ecosystems may not, and anyway you need a file whereas chafa can work with streams.
I'd find it very useful to be able to query a terminal to see if it has font support for a given list of characters.
This would allow TUIs to use recent unicode characters which may not be supported (e.g. Symbols for Legacy Computing), or private use characters (e.g. powerline symbols & font-awesome icons), while falling back to a more universally supported character in terminals that do not support them.
It should in theory be possible to mount the new virtual package over the lower module - but I don't think works currently (I'll have to test this). Doing this would make modifications available globally like you describe.
I'm working on what is effectively a fork of prompt_toolkit [1], which supports many modern terminal features I needed for euporie [2], such as terminal graphics, extra text styles, color palette detection, terminal clipboard, synchronized outputs, CSI-u, mouse pixel positioning, etc.
I'd be very interested to test it's performance and to read your code (I'm not an AI, promise :)
[1] https://github.com/joouha/euporie/tree/dev/packages/apptk
[2] https://github.com/joouha/euporie
reply