Commit Graph

491 Commits

Author SHA1 Message Date
Aram Drevekenin
4905ae65b8
docs(changelog): bold/dim reset fix 2022-11-02 19:25:50 +01:00
Aram Drevekenin
897038638d
docs(changelog): clear floating panes indication 2022-11-02 18:12:37 +01:00
Aram Drevekenin
97131fd7f8
docs(changelog): backslash config convert fix 2022-11-02 16:45:20 +01:00
Aram Drevekenin
4ab04c59a2
docs(changelog): terminating char in search 2022-11-02 14:36:29 +01:00
Jae-Heon Ji
8f293f584f
docs(changelog): remove space from shared_except 2022-11-02 20:17:23 +09:00
har7an
e45a3e5826
errors: Don't unwrap in server::os_input_output (#1895)
* server/os_io: Redefine `ServerOsApi` result types

to use `anyhow::Result` instead. This mostly makes the need of custom
`SpawnTerminalError` obsolete (tbd in subsequent commits) and unifies
error handling across the application.

* utils/errors: Implement new `ZellijError` type

to replace any previously defined, isolated custom error types
throughout the application. Currently implements all error variants
found in `SpawnTerminalError`.

In the long term, this will allow zellij to fall back to a single error
type for all application-specific errors, instead of having different
error types per module.

* server/unit/screen: Impl new `ServerOsApi`

with updated `Result`-types.

* server/tab/unit: Impl new `ServerOsApi`

with updated `Result`-types.

* server/os_io: Impl new `ServerOsApi`

with updated `Result`-types.

* utils/ipc: Return `anyhow::Error` in `send`

rather than a `&'static str`, which isn't compatible with
`anyhow::Context`.

* server/tab: Handle `Result` in `resize_pty!`

which is returned due to the changed return types in `ServerOsApi`.

* server/tab: Handle new `Result`s

originating in the change to the `ServerOsApi` trait definition.

* server/screen: Handle new `Result`s

originating in the change to the `ServerOsApi` trait definition.

* server/panes/tiled: Handle new `Result`s

originating in the change to the `ServerOsApi` trait definition.

* server/panes/floating: Handle new `Result`s

originating in the change to the `ServerOsApi` trait definition.

* server/lib: Unwrap on new `Result`s

originating in the change to the `ServerOsApi` trait definition. The
functions here don't return a `Result` yet, this is better left to a
follow-up PR.

* server: Remove `SpawnTerminalError`

and make use of the new `ZellijError` instead. Make use of `anyhow`s
downcast capabilities to restore the underlying original errors where
necessary, as was done previously. This gives us the flexibility to
attach context information to all errors while still allowing us to
handle specific errors in greater detail.

* server/pty: Fix vars broken in rebase

* server/os_io: Remove last `SpawnTerminalError`

* changelog: Add PR #1895
2022-11-02 05:29:50 +00:00
Aram Drevekenin
cd2f5c2e7d
docs(changelog): suspended command panes 2022-11-01 09:08:17 +01:00
Aram Drevekenin
6d29c6951e
docs(changelog): status bar fix 2022-10-31 19:41:36 +01:00
Thomas Linford
1704d11698
docs(changelog): mouse mode runtime toggle 2022-10-31 17:06:14 +01:00
Thomas Linford
5c2f5f8470
docs(changelog): setup --clean panic fix 2022-10-31 16:38:54 +01:00
har7an
417b4a4ec5
errors: Don't unwrap in zellij_server::output (#1878)
* server/output: Don't unwrap

and return `Result` types where appropriate instead.

* server: Handle new `Result`s from `output`

* server/tab/unit: Unwrap new `Result`s

* changelog: Add PR #1878

Don't unwrap in `zellij_server::output`.
2022-10-30 06:02:03 +00:00
har7an
60322e969f
errors: Don't unwrap in server::terminal_bytes (#1876)
* server/terminal_bytes: Don't unwrap

and return `Result`s instead, where appropriate.

* changelog: Add PR #1876

Don't unwrap in `zellij_server::terminal_bytes`.
2022-10-28 17:12:05 +00:00
Jae-Heon Ji
086b5d28fb
docs(changelog): update docs theme example dir 2022-10-29 01:07:18 +09:00
har7an
aa7fe853d6
changelog: Add PR #1872
Remove calls to `unwrap` in `zellij_server::pty_writer`
2022-10-28 14:44:31 +00:00
har7an
f23108f63f
changelog: Add PR #1870
Remove calls to `unwrap` in `zellij_server::ui::*`
2022-10-28 14:16:27 +00:00
Jae-Heon Ji
668df6bbd7
docs(changelog): support multiple themes 2022-10-28 22:50:00 +09:00
Thomas Linford
9fa73d5758
docs(changelog): add everforest themes 2022-10-28 13:31:19 +02:00
Aram Drevekenin
82c365831e
docs(changelog): close on exit 2022-10-28 13:04:54 +02:00
har7an
eed9541a74
changelog: Add PR #1840
improve error handling in `zellij_server::pty`
2022-10-26 06:53:42 +00:00
Aram Drevekenin
5793af7655 chore(version): bump development version 2022-10-25 11:43:53 +02:00
Jae-Heon Ji
63cf3a6b01
docs(changelog): add help to cli options 2022-10-24 00:47:07 +09:00
har7an
75801bdb0e
plugins: Improve error handling on plugin version mismatch (#1838)
* server/tab: Don't panic in `Pane::render`

and do not crash the application on failure to receive a render update
from plugins any longer. Instead, will print a simple string with a hint
to check the application logs, where a more thorough error indication
can be found.

* utils/errors: re-export `anyhow::Error`

to create ad-hoc errors with custom error types, without having to wrap
them into a `context()` before to turn the into anyhow errors.

* plugins: Check plugin version on startup

and terminate execution with a descriptive error message in case the
plugin version is incompatible with the version of zellij being run.

* server/wasm_vm: Add plugin path in version error

so the user knows which plugin to look at in case they're using custom
plugins.

* server/wasm_vm: Check plugin version for equality

Previously we would accept cases where the plugin version was newer than
the zellij version, which doesn't make a lot of sense.

* server/wasm_vm: Prettier error handling

in call to `wasmer::Function::call` in case a plugin version mismatch
can occur.

* tile: Install custom panic handler

that will print the panic message to a plugins stdout and then call a
panic handler on the host that turns it into a real application-level
panic.

* tile: Catch errors in event deserialization

and turn them into proper panics. These errors are symptomatic of an
uncaught plugin version mismatch, for example when developing from main
and compiling zellij/the plugins from source. Normal users should never
get to see this error.

* utils/errors: Improve output in `to_stdout`

for anyhow errors. The default anyhow error formatting of `{:?}` is
already very good, and we just made it worse by trying to invent our own
formatting.

* tile: Reword plugin mismatch error message

* zellij: Apply rustfmt

* changelog: Add PR #1838

Improve error handling on plugin version mismatch.

* server/wasm_vm: Rephrase error in passive voice
2022-10-23 13:14:24 +00:00
har7an
d36e91e072
changelog: Add PR #1808
Improve error handling in `server/route`.
2022-10-21 13:51:01 +00:00
har7an
348a197eb9
changelog: Add PR #1827
which removes calls to `unwrap` from `wasm_vm` and prints sensible error messages when errors in the plugins occur.
2022-10-20 15:51:23 +00:00
Aram Drevekenin
8431b9e0ef
docs(changelog): tab cwd in layouts 2022-10-20 15:24:28 +02:00
Aram Drevekenin
ebf61f6ff2
docs(changelog): scroll region fix 2022-10-19 18:37:18 +02:00
Jae-Heon Ji
ca182fd216
docs(changelog): update DumpScreen action 2022-10-19 22:53:25 +09:00
Aram Drevekenin
5878e9f6f8
docs(changelog): upgrade log4rs 2022-10-19 09:26:59 +02:00
Aram Drevekenin
130c16beb3
docs(changelog): default to vi editor 2022-10-18 17:37:16 +02:00
Aram Drevekenin
5c8cded2f5
docs(changelog): floating panes grouped 2022-10-18 16:45:19 +02:00
har7an
d533299656
changelog: Add PR #1805
Add tips for code contributions to CONTRIBUTING, and expand the error docs with regard to how to handle `Option` types.
2022-10-18 14:16:30 +00:00
Aram Drevekenin
12d35bded5
docs(changelog): zellij run improvements 2022-10-17 19:40:34 +02:00
har7an
4562982409
changelog: Add PR #1800
for logging of IPC messages in `thread_bus` only when the `--debug` flag is specified.
2022-10-17 15:36:43 +00:00
Aram Drevekenin
2ae057d061
docs(changelog): edit panes in layouts 2022-10-14 17:45:00 +02:00
Aram Drevekenin
8c2b576b67
docs(changelog): global cwd 2022-10-14 15:09:05 +02:00
Aram Drevekenin
5c43a59e00
docs(changelog): layout fixes 2022-10-13 13:56:37 +02:00
har7an
8d56def4fc
zellij/commands: Prevent recursive sessions (#1766)
* zellij/commands: Prevent recursive sessions

with session names specified in layout files. A "recursive session" is
created when, while running inside some zellij session, a user attempts
to spawn zellij and make it attach to that same session.

When attaching via CLI (`zellij attach`) we explicitly check for this
condition and error out when needed.

However, besides `zellij attach` it is also possible to declare the
session to attach to in layout files like so:

```yaml
session:
  name: "foo"
```

This takes a different codepath when starting zellij, and hence bypases
the checks we already have in place to avoid recursive sessions. Hence,
we implement the check in the other codepath, too, and prevent recursive
sessions from happening for good.

Fixes: #1735

* changelog: fix recursive zellij sessions
2022-10-13 08:17:54 +00:00
Aram Drevekenin
e07dfcde78
docs(changelog): session-name cli fix 2022-10-12 15:36:10 +02:00
Aram Drevekenin
2c5b2784ba
docs(changelog): duplicate layout errors 2022-10-12 14:30:41 +02:00
Aram Drevekenin
2e5aaeb739
docs(changelog): move item to the right place 2022-10-12 13:05:31 +02:00
Aram Drevekenin
56d6423816
docs(changelog): mixed nodes layout error 2022-10-12 13:04:17 +02:00
Thomas Linford
694afd2239
fix(tab): frameless pane size wrong after closing other panes (#1776)
always recompute pane frames after closing a pane
2022-10-12 11:29:17 +02:00
Aram Drevekenin
46dd8d4473
docs(changelog): escapes when converting configs 2022-10-12 10:50:14 +02:00
Aram Drevekenin
f6fa521313
docs(changelog): command pane 2022-10-11 16:46:55 +02:00
har7an
cb926119bc
changelog: Add PR 1775
which improves error formatting in `server/thread_bus` and removes calls to `unwrap`, too.
2022-10-07 10:00:08 +00:00
har7an
bc04983f06
changelog: Add pull 1748
which removes calls to `unwrap` in `zellij_server::tab`.
2022-10-06 06:54:47 +00:00
Aram Drevekenin
46edc590ec
docs(changelog): switch config/layout/theme language to KDL 2022-10-05 07:45:43 +02:00
a-kenji
917e9b2ff0 docs(changelog): add darwin dependencies 2022-10-04 12:24:17 +02:00
har7an
9135eceac1
changelog: mention PR 1770
to improve error handling in screen thread private functions
2022-10-04 09:45:36 +00:00
har7an
77f05f0f12
Fix: issue 1734 (#1749)
* server/tab: Check suppressed panes

when writing to a pane by ID. Previously only the tiled and floating
panes would be searched for a pane of a given ID.

Fixes: #1734

* server/tab/unit: Test writing to suppressed panes

* docs: fix server panics when writing to suppressed panes
2022-09-23 05:28:35 +00:00