Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(ux): cache stdin queries on startup (remove startup delay) #2173

Merged
merged 2 commits into from
Feb 17, 2023

Conversation

imsnif
Copy link
Member

@imsnif imsnif commented Feb 17, 2023

TLDR

This removes the vastly unpopular load screen we introduced in the previous version in favor of caching.

The story so far...

Zellij queries the terminal emulator for pixel/cell ratio values as well as default colors. We use this information mostly for responding to queries from apps that run inside panes. Since the terminal emulator responds through STDIN, we used to just ignore whatever the user typed for the first 0.5 seconds the app ran.

When some especially fast-reflexed users encountered this problem, we decided to add a loading screen for those 0.5 seconds to indicate that users should wait a moment before starting to type.

This too wasn't very popular, since even though now we were being open about this annoying hack, it still didn't feel nice to encounter this 0.5 second text flash every time we open a terminal.

With this change, we do this for the first time every version and then cache the result. To bust the cache, we would need to delete the file manually (or just delete the whole of ~/.cache/zellij).

Thank you for your patience :)

@imsnif imsnif temporarily deployed to cachix February 17, 2023 17:46 — with GitHub Actions Inactive
@imsnif imsnif temporarily deployed to cachix February 17, 2023 17:49 — with GitHub Actions Inactive
@imsnif imsnif merged commit 3a0e56a into main Feb 17, 2023
joshheyse pushed a commit to joshheyse/zellij that referenced this pull request Mar 11, 2023
…j-org#2173)

* fix(ux): cache stdin queries on startup

* style(fmt): rustfmt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant