You have a problem and you need a configuration language, so you pick YAML. Now you have two problems. Take a leaf out of Rust's book and use something simple and sane like TOML, YAML is a mess. See: https://github.com/cblp/yaml-sucks Otherwise this looks like a great project, please don't ruin it with YAML.
Zellij – A Terminal Workspace and Multiplexer
141–150 of 248 posts
Re: Zellij – A Terminal Workspace and Multiplexer
#142Earlier quoted context omitted.
I think JSON would be perfect if it a) allowed comments, and b) had multi-line strings. It has exactly five data types, each with very clear and distinct notation that nests consistently (the top level isn't somehow "special" and there's no messing with significant whitespace). Only two collection types: keyed, and unkeyed. In some sense it feels like the apotheosis of untyped data-modeling.
I just wish JSON had fixed decimal numbers, a timestamp type, and a binary blob type :/
Re: Zellij – A Terminal Workspace and Multiplexer
#143The first thing I noticed is that this interface is discoverable - it shows me what I can do, which is incredible and makes me want to use it. The main reason I've been a casual tmux user and not an advanced one despite using it for years, is because every time I want to try something new I have to google if it's possible.
The second thing I noticed is that it uses ctrl-r as a core shortcut. Mega problem: ctrl-r is a built-in bash feature which I use every day to recall previous commands. This makes me think I can't use this tool at all.
I would suggest to consider taking a page from tmux's book. Just use a global modifier key. Ctrl-b is what tmux uses, so you know it's safe. Other software being developed knows they should avoid it, because tmux uses it. By also using it, you'd no longer have to dance around the global space of what shortcuts every software in existence is using. Additionally, if you use ctrl-b to enable your commands, you can minimize your interface. Currently you're using two entire lines to display your menu. That's going to become tiring as I use zellij 8 hours a day for years. I'll have to hide it eventually. Instead, what if you reduced it to zero lines? Put "ctrl-b: menu" in the upper right of your title bar. Pressing ctrl-b now enables commands and shows what your next keypress will do. You have now (1) avoided breaking existing shortcuts, (2) aligned with established standards (3) given some familiarity to welcome tmux users (4) expanded visible screen space and (5) simplified your menu system. You can also now remove ctrl-g since the interface is "locked" by default until I want to start interacting with it.
Anyway that's my 2 cents. Thanks for this exciting demo.
Re: Zellij – A Terminal Workspace and Multiplexer
#144Earlier quoted context omitted.
YAML sucks but so does TOML, especially when it comes to nested data structures like the layout.yaml shown on the front page. There are no good configuration languages in existence and there never will be. We have rejected Lisp/sexp so now we must suffer endlessly.
I think JSON would be perfect if it a) allowed comments, and b) had multi-line strings. It has exactly five data types, each with very clear and distinct notation that nests consistently (the top level isn't somehow "special" and there's no messing with significant whitespace). Only two collection types: keyed, and unkeyed. In some sense it feels like the apotheosis of untyped data-modeling.
https://thedailywtf.com/articles/the-inner-json-effect
“Tell us what you did to JDSL,” one of the VP’s asked.
“I don’t think I did anything,” Jake answered. “I’ve only been here two weeks, trying to learn JDSL and how the customer portal works. I don’t even know how to deploy it!”
“You made a few commits to Subversion!” Tom shouted.
“Well, yes. I added a few code comments, trying to–”
“You can’t use comments in JDSL!” Tom shouted. “THAT’S WHAT BROKE IT!!”
Re: Zellij – A Terminal Workspace and Multiplexer
#145I've been using tmux for quite a while, though at a fairly casual level. The first thing I noticed is that this interface is discoverable - it shows me what I can do, which is incredible and makes me want to use it. The main reason I've been a casual tmux user and not an advanced one despite using it for years, is because every time I want to try something new I have to google if it's possible. The second thing I not…
Re: Zellij – A Terminal Workspace and Multiplexer
#146Earlier quoted context omitted.
You can multiplex your SSH session and have several ssh commands running on the same connection (without having to type the password/check the security key again). Check the ControlMaster option for SSH.
And this is better than tmux... Why?
Tmux is the UI for switching between ssh sessions sharing the connection.
Re: Zellij – A Terminal Workspace and Multiplexer
#147Earlier quoted context omitted.
Yeah, I think that the main benefit of tmux is session management. Tiling window managers can replace tmux panes.
Tiling window managers cannot replace a multiplexer's knowledge about the session. I use a multiplexer because it lets me instantly open a new terminal in the same directory I'm currently working in. Furthermore it can open the terminal's buffer in Vim, letting me select and copy text using all features and shortcuts I'm used to. Doing the same by scrolling around, selecting snippets using the mouse and pressing Ctrl…
You can add a keybinding for this with alacritty:
{ key: N, mods: Command, action: SpawnNewInstance }
> Furthermore it can open the terminal's buffer in Vim, letting me select and copy text using all features and shortcuts I'm used toalacritty has vi mode which gives you all of those keybindings without having to open vim (ctrl+shift+space).
Re: Zellij – A Terminal Workspace and Multiplexer
#148Earlier quoted context omitted.
YAML sucks but so does TOML, especially when it comes to nested data structures like the layout.yaml shown on the front page. There are no good configuration languages in existence and there never will be. We have rejected Lisp/sexp so now we must suffer endlessly.
Take a look at HOCON (Human-Optimized Config Object Notation) https://github.com/lightbend/config/blob/main/HOCON.md
So, the project you linked to is Java / Scala: https://github.com/lightbend/config
And there're also (basic? complete?) HOCON parsers in Javascript and Rust — I investigated this a while ago, because I want to use HOCON everywhere in my projects:
https://docs.rs/hocon/0.5.1/hocon/ (Rust)
https://www.google.com/search?q=hocon+javascript (Js, a few different)
The Rust version:
> This implementation goal is to be as permissive as possible, returning a valid document with all errors wrapped in `Hocon::BadValue` when a correct value cannot be computed
How nice :- ) (it seems to me)
Re: Zellij – A Terminal Workspace and Multiplexer
#149I've been using tmux for quite a while, though at a fairly casual level. The first thing I noticed is that this interface is discoverable - it shows me what I can do, which is incredible and makes me want to use it. The main reason I've been a casual tmux user and not an advanced one despite using it for years, is because every time I want to try something new I have to google if it's possible. The second thing I not…
You can lock the interface with ctrl-g and then all keys pass through.
Re: Zellij – A Terminal Workspace and Multiplexer
#150Shouldn't that be completely opaque to the user? I don't have any idea what programming language most of the software I use is written in.
If it's faster or more stable than tmux, shouldn't that be what's advertised, rather than implementation details? Reading the page, what catches my eye is the webasm plugin system (although it's not immediately obvious to me what I'd use that for).