* work
* work
* work
* work
* work
* more work
* work
* work
* work
* hack around stdin repeater
* refactor(sixel): rename sixel structs
* feat(sixel): render text above images
* fix(sixel): reap images once they're past the end of the scrollbuffer
* fix(sixel): display images in the middle of the line
* fix(sixel): render crash
* fix(sixel): react to SIGWINCH
* fix(sixel): behave properly in alternate screen mode
* fix(sixel): reap images on terminal reset
* feat(sixel): handle DECSDM
* fix(terminal): properly respond to XTSMGRAPHICS and device attributes with Sixel
* Add comment
* fix(sixel): hack for unknown event overflow until we fix the api
* feat(input): query terminal for all OSC 4 colors and respond to them in a buggy way
* fix(sixel): do not render corrupted image
* feat(input): improve STDIN queries
* fix(client): mistake in clear terminal attributes string
* fix(ansi): report correct number of supported color registers
* fix(sixel): reap images that are completely covered
* style(comment): fix name
* test(sixel): infra
* test(sixel): cases and fixes
* fix(sixel): forward dcs bytes to sixel parser
* refactor(client): ansi stdin parser
* refactor(output): cleanup
* some refactorings
* fix test
* refactor(grid): sixel-grid / sixel-image-store
* refactor(grid): grid debug method
* refactor(grid): move various logic to sixel.rs
* refactor(grid): remove unused methods
* fix(sixel): work with multiple users
* refactor(pane): remove unused z_index
* style(fmt): prepend unused variable
* style(fmt): rustfmt
* fix(tests): various apis
* chore(dependencies): use published version of sixel crates
* style(fmt): rustfmt
* style(fmt): rustfmt
* style(lint): make clippy happy
* style(lint): make clippy happy... again
* style(lint): make clippy happy... again (chapter 2)
* style(comment): remove unused
* fix(colors): export COLORTERM and respond to XTVERSION
* fix(test): color register count
* fix(stdin): adjust STDIN sleep times
* zellij-tile: Move `data` to zellij-utils
The rationale behind this is that all components of zellij access the
data structures defined in this module, as they define some of the most
basic types in the application. However, so far zellij-tile is treated
like a separate crate from the rest of the program in that it is the
only one that doesn't have access to `zellij-utils`, which contains a
lot of other data structures used throughout zellij.
This poses issues as discussed in
https://github.com/zellij-org/zellij/pull/1242 and is one of the reasons
why the keybindings in the status bar default plugin can't be updated
dynamically. It is also the main reason for why the keybindings are
currently passed to the plugin as strings: The plugins only have access
to `zellij-tile`, but since this is a dependency of `zellij-utils`, it
can't import `zellij-utils` to access the keybindings.
Other weird side-effect are that in some places `server` and `client`
have to access the `zellij-tile` contents "through" `zellij-utils`, as
in `use zellij_utils::zellij_tile::prelude::*`.
By moving these central data structures to one common shared crate
(`zellij-utils`), `zellij-tile` will be enabled to import `zellij-utils`
like `screen` and `client` already do. This will, next to other things,
allow dropping a lot of `std::fmt::Fmt` impls needed to convert core
data structures into strings and as a consequence, a lot of string
parsing in the first place.
* utils: Integrate new `data` module, bump rust ver
Integrates the `data` module that was previously part of `zellij-tile`
to allow sharing the contained data structures between all components of
zellij.
This allows `zellij-tile` to use `utils` as a dependency. However, since
`tile` is build against the wasm target, it cannot include all of
`zellij-utils`, since a lot of dependencies there cannot compile with
`wasm` as target (Examples include: termwiz, log4rs, async-std). Thus we
make all the dependencies that cannot compile against `wasm` optional
and introduce a new feature `full` that will compile the crate with all
dependencies. Along with this, modify `lib.rs` to include most of the
data structures only when compiling against the `full` feature.
This makes the compiles of `zellij-tile` lighter, as it doesn't include
all of `utils`. As a side effect, due to the dependency notation for the
optional dependencies (See
https://doc.rust-lang.org/cargo/reference/features.html#optional-dependencies),
we bump the rust toolchain version to 1.60.0.
* tile: Import `data` from zellij-utils
Add `zellij-utils` as a dependency to `zellij-tile` and allow us access
to the `data` module defined there. Update the re-export in the
`prelude` such that from all of the plugins points of view *absolutely
nothing changes*.
* utils: Fix `data` module dependency
Since the `data` module has been migrated from `zellij-tile` to
`zellij-utils`, we import it from `zellij-utils` directly now.
Also unify the imports for the `data` module members: We import all of
the through `data::` now, not through a mixture of `data::` and
`prelude::`.
* client: Fix `data` module dependency
Since the `data` module has been migrated from `zellij-tile` to
`zellij-utils`, we import it from `zellij-utils` directly now.
Also unify the imports for the `data` module members: We import all of
the through `data::` now, not through a mixture of `data::` and
`prelude::`.
Add the "full" feature flag to the `zellij-utils` dependency so it
includes all the components we need.
* server: Fix `data` module dependency
Since the `data` module has been migrated from `zellij-tile` to
`zellij-utils`, we import it from `zellij-utils` directly now.
Also unify the imports for the `data` module members: We import all of
the through `data::` now, not through a mixture of `data::` and
`prelude::`.
Add the "full" feature flag to the `zellij-utils` dependency so it
includes all the components we need.
* tests: Fix `data` module dependency
Since the `data` module has been migrated from `zellij-tile` to
`zellij-utils`, we import it from `zellij-utils` directly now.
* utils: Remove "full" feature
in favor of conditional compilation using `target_family`. Replace the
rust 1.60 method of specifying optional dependencies based on features
and optionally include the dependencies only when not building for wasm
instead. (I.e. `cfg(not(target_family = "wasm"))`)
* cargo: Update module dependencies
since `client`, `server` and `tile` now all depend on `utils` only.
* feat: add capability to dispatch actions from cli
Add capability to dispatch actions from the cli.
Can be invoked through `zellij action [actions]`
Automatically sends the action either to the current session,
or if there is only one session to the single session.
If there are multiple sessions, and no session is specified it will
error out.
Example:
1.
```
zellij action "[NewTab: , NewTab: ]"
```
2.
```
zellij -s fluffy-cat action '[NewPane: , WriteChars: "echo Purrr\n" ]'
```
3.
```
zellij -s fluffy-cat action '[ CloseTab, ]
```
* add: error message on malformed input
Add an error message on malformed input, for the `action`'s dispatch.
Rather than resulting in a panic.
* add: function to query the client id
* add: send specific actions to certain clients
Adds ability to send actions, that don't impact the server state
to all connected clients. For example `MoveFocus`
* add: client_id to non blocking actions
* chore(fmt): `cargo fmt`
* add: pick correct session, if there is exactly one
* add: use correct `client_id` for detach action
* add: make `[ ]` opaque to the user
* add: miette to toplevel to improve error message
* add: fake client reading configuration
Add the fake client reading configuration files,
this allows actions, that rely on configuration work
correctly. This is an intermediate solution, and should ideally not
be needed. It would be better if most of this state would be handled
by the server itself.
* chore(fmt): rustmt
* add: ability to detach multiple clients
Add ability to detach multiple clients at the same time.
* remove: obsolete functionality
* remove: unused functionality
* add: send correct action upon exiting
* chore(update): cargo update
* add(option): `default_layout`
Add `option` `default_layout` / `default-layout`,
that allows specifying a different layout, that should
be loaded on start.
Eg:
```
default_layout: compact
```
* add(manpage): `default_layout`
* initial commit for opening the current buffer in an editor
* fix(editor): take hidden panes into consideration when manipulating tiled grid
* when closing an edit buffer, take the geometry of the replaced buffer from the closed buffer
* if the floating panels are displayed, don't add to hidden panels the current buffer
* strategy changing - put the panels inside a suppressed_panels HashMap instead of hidden_panels
* Revert "strategy changing - put the panels inside a suppressed_panels HashMap instead of hidden_panels"
This reverts commit c52a203a20.
* remove the floating panes by moving them to the tiled_panes in hidden_panels
* feat(edit): open editor to correct line and don't crash when none is set
* formatting
* feat(edit): use suppressed panes
* style(fmt): rustfmt and logs
* style(fmt): clean up unused code
* test(editor): integration test for suppressing/closing suppressed pane
* test(e2e): editor e2e test
* style(fmt): rustfmt
* feat(edit): update ui and setup
* style(fmt): rustfmt
* feat(config): allow configuring scrollback_editor explicitly
* style(fmt): rustfmt
* chore(repo): build after merging
Co-authored-by: Aram Drevekenin <aram@poor.dev>
* Initial commit for fixing #1353
* adding a new line between the lines_above and the viewport
* changes following code review
* implementing a test case for the dump screen
* implemented test case for dump_screen
* better regexp replace
* fixes following code review
* style(api): remove extraneous method in plugin pane
* style(fmt): rustfmt
* style(tests): fix method name
Co-authored-by: Aram Drevekenin <aram@poor.dev>
* feat(copy): add copy_on_select option
with default value of true, keep current behavior of automatically
copying selection to clipboard when done selecting.
with copy_on_select = false, on mouse release the selection remains, and
can be copied with the `Copy` action.
* add example to default.yaml
* add copy action example to default.yaml, cleanup
* fix updated tab tests
* fix selection changing while scrolling after release
* fix clippy warnings
* feat(signals): get pixel info from terminal emulator
* feat(signals): query for pixel info on sigwinch
* feat(signals): reply to csi 14t and csi 16t
* style(fmt): rustfmt
* style(comments): remove outdated
* Remove gray from theme config and improve colors for dark themes
* improve theme usage
* Add new themes and minor fixes
* improve tokyo-night theme according to new changes
* Fix formatting
* change default black colour
* docs(CHANGELOG): #1274 improve themes
* feat(ui): change from non-working alt-brackets to alt-arrows
* style(fmt): rustfmt
* fix: improve parsing of `alt` combination keys
The binding of the keys can now be specified with:
- Alt: 'c'
- Alt: Up
- Alt: Down
- Alt: Left
- Alt: Right
* chore(fmt): rustfmt
Co-authored-by: a-kenji <aks.kenji@protonmail.com>
* feat(ui): round frame corners
* Allow rounded_corners to be set without a palette
* Revert "Allow rounded_corners to be set without a palette"
This reverts commit 9271a4b545.
* fix(style): remove redundant code
* fix(style): clippy lints that somehow got missed
* feat(config): add ui config section
fix(wasm_vm): use `cache_dirs` for ephemeral plugin data
Use proper `cache_directories` by default, that users can be expected
to have proper write permissions for.
The directory is used for plugin hashes, and compilation data.
* fix(feat): `disable_automatic_asset_installation`
This fixes a regression in the feature system:
The asset installation didn't get turned off by the feature.
Add error logging to the install functions.
Properly show features in setup
disable `mkdir` in `wasm_vm` on `feature-disable-asset-installation`
Alternative:
Is this even needed? We make sure the directory is there upon the
normal asset installation.
fixes#1130
And infrastructure to make it possible
to add more dynamic completions for
different shells in the future.
eg:
```
zellij attach [completes-active-sessions]
zellij kill-session [completes-active-sessions]
```
fixes: #1030
Add ability to set `ENVIRONMENT VARIABLES` from the
config and the layout files.
example:
```
env:
ZELLIJ_CONFIG:
DEFAULT
```
or
```
env:
ZELLIJ_LAYOUT_NAME:
BUILD_SESSION
```
If two keys conflict (configuration and layout), then the key
from the layout is used.
fixes: #1059
* feat(layout): add focus attribute in layout
* feat: add state of focus to tab
* chore: i love clippy
* test(layout): update focus options
* feat: add focus pane
* feat: apply focus-pane when layout is only loaded
* change the instruction name for focus-on-tab
* chore: apply cargo-fmt
* test: add e2e testcase
* Read pane name from layout
* Update pane name at runtime
* Fix tests
* prefer and render pane name over pane title
* fix clippy errors
* fix after rebase
feature(layout): add layout config (#866)
* It is now possible to configure zellij through a layout:
The config file and the layout file will be merged, on conflicting
options the order is as follows:
1. config options `zellij options`
2. layout
3. config
Example:
```
---
template:
direction: Horizontal
parts:
- direction: Vertical
body: true
- direction: Vertical
borderless: true
split_size:
Fixed: 1
run:
plugin:
location: "zellij:tab-bar"
default_shell: fish
```
* fix(options): handling ond verwriting cli opts
* previously it was only possible to turn off certain features with a
command line option, now it is possible to also overwrite this
behavior in a sane way, for that some breaking changes happened:
following options got renamed and inverted:
```
disable_mouse_mode -> mouse_mode
no_pane_frames -> pane_frames
```
following cli options got added:
```
mouse-mode [bool]
pane-frames [bool]
simplified-ui [bool]
```
the following cli flag got removed:
```
simplified-ui
```
They can be specified in the following way:
```
zellij options --mouse-mode true
```
in order to enable the mouse mode, even if it is turned off in the
config file:
```
mouse_mode: false
```
The order is now as follows:
1. corresponding flag (`disable-mouse-mode`)
2. corresponding option (`mouse-mode`)
3. corresponding config option (`mouse_mode`)
* add: options and flags for the same value conflict
* example:
```
zellij options --mouse-mode true --disable-mouse-mode`
```
```
$ error: The argument '--mouse-mode <mouse-mode>' cannot be used with '--disable-mouse-mode'
```
add the ability to toggle boolean options with a cli flag:
example:
if the pane frames are turned off in the config file,
then passing in the `--no-pane-frames` flag will toggle the
pane frames on
* feat: add session configuration to layout template
WIP: prototyping for issue #611
* test(layout): add session name
* feat(layout): add cond flow to check session name
* feat(layout): update session
* feat: add function to attach a session
* fix(layout): update feedback
* attach option only works when layout template exists.
* feat(layout): add conditional for session-layout
* update default attach value
* Half-page scroll actions #794
* fix(performance): do not hang when resizing large line wraps (#814)
* fix(performance): do not hang when resizing large line wraps
* style(fmt): make rustfmt happy
* style(clippy): make clippy happy
* docs(changelog): scroll fix
* fix(compatibility): home and end key fix (#815)
* fix(compatibility): handle home/end keys properly from terminfo
* style(fmt): make rustfmt happy
* style(fmt): remove unused import
* docs(changelog): home end key fix
* docs(changelog): fix link
* fix(typo): Correct typo from `occured` to `occurred` (#821)
* docs(changelog): fix a typo
* fix(docs): fix wrong arguments for `cargo make run` given in CONTRIBUTING.md (#819)
* docs(changelog): update `cargo-make` for `v0.35.3`
* fix(warning): Fix an unused import warning of std::fs on macos (#820)
* docs(changelog): fix unused import on darwin
* add: `WriteChars` action (#825)
* Behaves like the `Write` action, but one can specify
strings themselves instead of their bytecodes.
Usage:
WriteChars: "cargo make test",
* docs(changelog): Add `WriteChars` action
* fix(docs): Fix a typo and some grammatical errors in bug_report.md (#826)
* docs(changelog): fix typo bug_report template
* add: `rust-version` (msrv) field to `Cargo.toml` (#828)
* specifies the minimum version the package can be compiled with,
may be ignored with `--ignore-rust-version` option
ref: https://doc.rust-lang.org/nightly/cargo/reference/manifest.html#the-rust-version-field
* docs(changelog): add `rust-version` to `Cargo.toml`
* fix(unix): forkpty => openpty (#830)
* fix(unix): forkpty => openpty
* style(fmt): make rustfmt happy
* docs(changelog): forkpty => openpty
* Fix: move `colors_transform` to `colorsys` (#832)
* `colors_transform` is deprecated and superceded by `colorsys`
ref: https://crates.io/crates/colors-transform
* docs(changelog): `colors_transform` to `colorsys`
* feat(ui): add right-click support to plugins
* chore(docs): update changelog
* chore(warnings): remove unused imports (#833)
* rename var sroll_rows and review snapshots
* style(fmt): make rustfmt happy
Co-authored-by: Aram Drevekenin <aram@poor.dev>
Co-authored-by: Ken Matsui <26405363+ken-matsui@users.noreply.github.com>
Co-authored-by: a-kenji <aks.kenji@protonmail.com>
Co-authored-by: Tw <tw19881113@gmail.com>
Co-authored-by: Brooks Rady <b.j.rady@gmail.com>
feat(attach): Support `--first` option for `attach` sub-command to let zellij choose the alphabetically first session; resolve#823
fix(attach-first): Fix `--first` option to choose the first created session in the existent sessions
feat(attach): Support `--index` option to choose the session indexed by provided number like -t option of tmux
feat(attach): Support listing active sessions with index when a provided number is not found in the active sessions
feat(attach): Support listing active sessions with index when a provided number is not found in the active sessions
feat: Add anyhow to uniformly treat error types and avoid panics
* feature(resize): Non directional resize
* Implement special cases
* fix resizing for panes that have `+` cross section
* fix resizing for panes that have `T` cross section
* fix panics
* Add Nondirection resize keys to plugin
* fix formatting
* fix: clippy warnings
* fix the last edge case
* implemented some of the suggested changes
* Remove helper function and elevate comment to top of function
* Use `=` to keep it consistent with Normal mode mapping as its easier to use
* Remove extra reference borrowing
* fix an edge case
* add test for nondirectional resize increase/decrease
* fix(controls): add + to resize
* refactor(resize): simplify methods
* fix(resize): properly resize opposite corner pane
Co-authored-by: Aram Drevekenin <aram@poor.dev>
Fix#714
Allow empty `config` and `layout` files
- Currently empty files are parsed as yaml documents, since they
are empty they are invalid yaml files and a deseralization error would
follow.
Now we ignore the incorrect yaml on an empty document and treat it as
an empty yaml document.
Eg:
```
```
and
```
---
```
Are now treated equally.
Alternative: Keep treating the files as `yaml` documents.
* feat(sessions): mirrored sessions
* fix(tests): input units
* style(fmt): make rustfmt happy
* fix(tests): make mirrored sessions e2e test more robust
* refactor(sessions): remove force attach
* style(fmt): rustfmtify
* docs(changelog): update change
* fix(e2e): retry on all errors
* feat(plugins-manifest): Add a plugins manifest to allow for more configuration of plugins
* refactor(plugins-manifest): Better storage of plugin metadata in wasm_vm
* fix(plugins-manifest): Inherit permissions from run configuration
* refactor(plugins-manifest): Rename things for more clarity
- The Plugins/Plugin structs had "Config" appended to them to clarify
that they're metadata about plugins, and not the plugins themselves.
- The PluginType::OncePerPane variant was renamed to be just
PluginType::Pane, and the documentation clarified to explain what it
is.
- The "service" nomenclature was completely removed in favor of
"headless".
* refactor(plugins-manifest): Move security warning into start plugin
* refactor(plugins-manifest): Remove hack in favor of standard method
* refactor(plugins-manifest): Change display of plugin location
The only time that a plugin location is displayed in Zellij is the
border of the pane. Having `zellij:strider` display instead of just
`strider` was a little annoying, so we're stripping out the scheme
information from a locations display.
* refactor(plugins-manifest): Add a little more documentation
* fix(plugins-manifest): Formatting
Co-authored-by: Jesse Tuchsen <not@disclosing>
Allow specifying only the tab name in the `tabs` section
- For example this is now possible:
```
tabs:
- name: first
parts:
- direction: Vertical
- direction: Vertical
- name: second
- name: third
```
For that the tab section defaults the direction to
`direction::Horizontal`
- Adds an error upon specifying a tab name inside the `parts` section
of the tab-layout
fixes#688
- the `options` subcommand of `attach` functions the same,
as the `options` subcommand of creating the normal session,
but not every option will have an effect on reattaching,
for example the `default_mode` setting would make no sense
to switch.
In the future it would make sense to be able to hot swap some
of the options on reattach, but we are not able to do that yet,
for example the `default_shell` one.
Eg:
```
zellij attach <session-name> options --theme <theme>
```
Improves the way empty valid `yaml` files are handled.
When deserializing a `config` or `layout` file, that is
an empty valid `yaml` file, eg:
```
---
```
We now assume the default configuration is desired.
* feat(cwd-pane): Add a new trait to get the cwd of a given pid
Co-authored-by: Quentin Rasmont <qrasmont@gmail.com>
* feat(cwd-pane): Allow for setting the cwd when spawning a new terminal
Co-authored-by: Quentin Rasmont <qrasmont@gmail.com>
* feat(cwd-pane): Add an active_pane field to the Pty struct
Co-authored-by: Quentin Rasmont <qrasmont@gmail.com>
* feat(cwd-pane): Update Pty with Tab's active pane id
Co-authored-by: Quentin Rasmont <qrasmont@gmail.com>
* feat(cwd-pane): Refactor spawn_terminal to use cwd by default
Co-authored-by: Quentin Rasmont <qrasmont@gmail.com>
* feat(cwd-pane): Fix tests and lints
Co-authored-by: Quentin Rasmont <qrasmont@gmail.com>
* feat(cwd-pane): Fix formatting
* feat(cwd-pane): Refactor child pid fetching to handle errors better
Instead of panicking when transfering the process id of the forked child
command we just return an empty process id.
* feat(cwd-pane): Add non Linux/MacOS targets for the get_cwd method.
This will allow Zellij to compile on non Linux/MacOS targets without
having an inherited cwd.
* feat(cwd-pane): Refactor spawn_terminal method to use ChildId struct.
The spawn_terminal methods been refactored to use the ChildId struct in
order to clarify what the Pid's returned by it are. The documentation
for the ChildId struct was improved as well.
* feat(cwd-pane): Fix tests/lints
Co-authored-by: Jesse Tuchsen <not@disclosing>
Co-authored-by: Quentin Rasmont <qrasmont@gmail.com>
* refactor(panes): move to parametric pane sizes
* Fixed the simpler errors by casting to usize
* The least I can do is pass the formatting check...
* Move to stable toolchain
* Well, it compiles?
* And now it doesn't! ;)
* Baseline functionality with the new Dimension type
* Working POC for percent-based resizing
* REVERT THIS COMMIT – DELETES TESTS
* Perfected the discrete resize algorithm
* Fixed fixed-size panes
* Basic bidirectional resize
* feat(resize): finalised parametric resize algorithm
* Reduce the logging level a bit
* Fixed nested layouts using percents
* Bug squishing for implicit sizing
* Here is a funky (read: rubbish) rounding approach
* And now it's gone again!
* Improve discretisation algorithm to fix rounding errors
* Fix the last layout bug (maybe?)
* Mixed explicit and implied percents work now
* Let's pretend that didn't happen...
* Make things a bit less crashy
* Crash slightly more for now (to find bugs)
* Manaually splitting of panes works now
* Start moving to percent-based resizes
* Everything but fullscreen seems to be working
* Fix compilatation errors
* Culled a massive amount of border code
* Why not pause to please rustfmt?
* Turns out I was still missing a few tests...
* Bringing back even more tests!
* Fix tests and pane boarders
* Fix the resize system without gaps
* Fix content offset
* Fixed a bug with pane closing
* Add a hack to fix setting of the viewport
* Fix toggling between shared borders and frames
* fix(tests): make e2e properly use PaneGeom
* style(fmt): make rustfmt happy
* Revert unintentional rounding of borders
* Purge some old borderless stuff
* Fix busted tab-bar shrinking
* Update E2E tests
* Finish implementing fullscreen!
* Don't crash anymore?
* Fix (almost) all tests
* Fix a lack of tab-stops
* All tests passing
* I really can't be bothered to debug a CI issue
* Tie up loose ends
* Knock out some lingering FIXMEs
* Continue to clean things up
* Change some naming and address FIXMEs
* Cull more code + FIXMEs
* Refactor of the resize system + polish
* Only draw frames when absolutely necessary
* Fix the tab-bar crash
* Fix rendering of boarders on reattach
* Fix resizing at small pane sizes
* Deduplicate code in the layout system
* Update tab-bar WASM
* Fixed the pinching of panes during resize
* Unexpose needlessly public type
* Add back a lost test
* Re-add tab tests and get them to compile
* All tabs need layouts
* Start fixing tests + bug in main
* Stabilize the resize algorithm rounding
* All tests from main are now passing
* Cull more dead code
* adjust example layouts and move them from `./example` to
`./example/layouts`
* simplify the deserialization of the layout
* layouts are now constructed as follows:
```
---
template:
direction: Horizontal
parts:
- direction: Vertical
borderless: true
split_size:
Fixed: 1
run:
plugin: tab-bar
- direction: Vertical
body: true # <== The body section specifies the position of the
# inserted tab
- direction: Vertical
borderless: true
split_size:
Fixed: 2
run:
plugin: status-bar
tabs:
- direction: Vertical
- direction: Vertical
```
It works as follows:
```
---
template:
direction: Horizontal
parts:
- direction: Vertical
split_size:
Fixed: 1
run:
plugin: tab-bar
- direction: Vertical
body: true
- direction: Vertical
split_size:
Fixed: 2
run:
plugin: status-bar
tabs:
- direction: Vertical
```
The tabs are created in the body section of the template.
* work
* resize working
* move focus working
* close pane working
* selection and fullscreen working
* pane title line
* titles and conditional scroll title
* whole tab resize working
* plugin frames working
* plugin splitting working
* truncate pane frame titles
* cleanup
* panes always draw their own borders - also fix gap
* toggle pane frames
* move toggle to screen and fix some bugs
* fix plugin frame toggle
* fix terminal window resize
* fix scrolling and fullscreen bugs
* unit tests passing
* e2e tests passing and new test for new frames added
* refactor: TerminalPane and PluginPane
* refactor: Tab
* refactor: moar Tab
* refactor: Boundaries
* only render and calculate boundaries when there are no pane frames
* refactor: Layout
* fix(grid): properly resize when coming back from alternative viewport
* style: remove commented code
* style: fmt
* style: fmt
* style: fmt + clippy
* docs(changelog): update change
Simplify deserialzation for layouts, config and config options.
Move the logic responsible to `Setup::from_options()` in order
to be able to parse `main.rs` as well as adding new command easier.
fixes#603, fixes#349
* The layout has now a unique `tabs` section,
that can be used, like the `parts` section,
everything that is not inside the tabs section
is assumed to be present on every single tab
that is opened.
This is a BREAKING CHANGE for people that use
custom `layouts` already, since the `tabs` section
is not optional - for clarity and intentionality reasons.
The functionality to specify multiple tabs is already there,
but is still gated behind a panic, until #621 is fixed.
So for now one tab can be specified to load on startup.
* The `NewTab` action can optionally be bound to open
a layout that is assumed to be in the new `tabs` section
This is a BREAKING CHANGE for people that have the
`NewTab` action already bound in the config file:
```
- action: [NewTab, ]
key: [F: 5,]
```
must now be specified as:
```
- action: [NewTab: ,]
key: [F: 5,]
```
Optionally a layout that should be opened on the new tab can be
specified:
```
- action: [NewTab: {
direction: Vertical,
parts: [ {direction: Horizontal, split_size: {Percent: 50}}, {direction: Horizontal, run: {command: {cmd: "htop"}}},],
key: [F: 6,]
```
or:
```
- action: [NewTab: {direction: Vertical, run: {command: {cmd: "htop"} }},]
key: [F: 7,]
```
or
```
- action: [NewTab: {
direction: Vertical,
parts: [ {direction: Vertical, split_size: {Percent: 25},run: {plugin: "strider" }}, {direction: Horizontal}],}, MoveFocus: Left,]
key: [F: 8,]
```
Adds the ability to dump the default layouts to
stdout, similar to the `zellij setup --dump-config`,
but now it needs the name of a currently existing
layout:
- default
- strider
- disable-status
`zellij setup --dump-layout [LAYOUT]`
* Initial mouse support
* enable mouse support (termion MouseTerminal)
* handle scroll up and down events
* Allow enabling/disabling of mouse reporting
Store the mouse terminal on OsInputOutput
* WIP: switch pane focus with mouse
* testing to get mouse character selection
* wip mouse selection
* wip: mouse selection
- initial handling of mouse events for
text selection within a pane
- wide characters currently problematic
- selection is not highlighted
* highlight currently selected text
* improve get currently selected text from TerminalPane
* copy selection to clipboard (wayland only for now)
* Add missing set_should_render on selection update
* Improve text selection
- Strip whitespace from end of lines
- Insert newlines when selection spans multiple lines
* Simplify selection logic
- Remove Range struct
- Selection is not an Option anymore, it's empty when start == end
* copy selection to clipboard with OSC-52 sequence
* Improve text selection with multiple panes
- Constrain mouse hold and release events to currently active pane
- Fix calculation of columns with side by side panes
* fix for PositionAndSize changes
* Fix mouse selection with full screen pane.
- Transform mouse event positions to relative when passing to pane.
* Move selection to grid, rework highlighting.
- Mark selected lines for update in grid output buffer, for now in the
simplest way possible, but can be made more efficient by calculating
changed lines only.
- Clear selection on pane resize.
- Re-add logic to forward mouse hold and release events only to
currently active pane.
* Tidy up selection
- add method to get selection line range
- add method to sort the current selection
* Grid: move current selection up/down when scrolling
- Make the selection work with lines in lines_above and lines_below
- Todo: update selection end when scrolling with mouse button being held
- Todo: figure out how to move selection when new characters are added.
* Grid: move selection when new lines are added
* Keep track of selection being active
- Handle the selection growing/shrinking when scrolling with mouse
button held down but not yet released.
* Improve selection end with multiple panes
* Tidying up
- remove logging statements, unused code
* Add some unit tests for selection, move position to zellij-utils
* Change Position::new to take i32 for line
* Grid: add unit tests for copy from selection
* add basic integration test for mouse pane focus
* Add basic integration test for mouse scroll
* Use color from palette for selection rendering
* Improve performance of selection render
- Try to minimize lines to update on selection start/update/end
* fixes for updated start method
* fix lines not in viewport being marked for rendering
- the previous optimization to grid selection rendering was always
adding the lines at the extremes of previous selection, causing problems
when scrolling up or down
- make sure to only add lines in viewport
* Disable mouse mode on exit
* use saturating_sub for usize subtractions
* copy selection to clipboard on mouse release
* disable mouse on exit after error
* remove left-over comments
* remove copy keybinding
* add default impl for selection methods in Pane
- remove the useless methods from Impl Pane in PluginPane
* move line diff between selections to selection
* add option to disable mouse mode
* Allow scrolling with mouse while selecting.
* move action repeater to os_input_output, change timeout to 10ms
- change repeater to take an action instead of a position with hardcoded
action
* replace mouse mode integration tests with e2e tests
* cleanup
* cleanup
* check if mouse mode is disabled from merged options
* fix missing changes in tests, cleanup
Add the ability to bind running commands to
an action.
Eg:
```
- action: [Run: {command: "htop",},]
key: [F: 6,]
``
Optionally the direction and arguments can be
specified:
```
- action: [Run: {command: "htop", args: ["-C",]},]
key: [F: 7,]
```
The directional splits are analogous to the `[NewPane]` splits.
```
- action: [Run: {command: "htop", args: ["-C",], direction: "Up"},]
key: [F: 8,]
```
* Adds an option to specify a default shell
either by specifying `default_shell: [PATH]`
in the config, or running zellij with
`zellij options --default-shell [PATH]`
* tests(integration): move basic integration tests to be unit tests
* fix(tests): silently fail threadbus for tests
* tests(unit): move compatibility tests to become unit tests for grid
* tests(unit): move close_pane tests to become unit tests for grid
* tests(e2e): move basic layout test to e2e
* tests(unit): move move_focus tests to be unit tests
* tests(unit): move resize_down tests to be unit tests
* tests(unit): move resize_left tests to be unit tests
* tests(unit): move resize_right tests to be unit tests
* tests(unit): move resize_up tests to be unit tests
* tests(infra): remove unused infra
* style(fmt): make rustfmt happy
* debug
* debug
* debug
* debug
* chore(test): shift volume mounting around because github actions is a special child
We add log4rs create for logging across Zellij. Additionally, we capture
`stderr` output from plugins and log it the same log file as other
Zellij logs.
* default layouts won't be installed by anymore,
instead they will be directly loaded
* `layout-dir` is now a subdirectory of the
`config-dir` by default, instead of the `data-dir`
POSSIBLE BREAKING CHANGE:
In case of having custom layouts in the previous
`layout-dir` one can switch either the layouts to
the new dir, or set the `layout-dir` to be the current
`layout-dir`
* it is possible to change the location of the `layout-dir`:
- `zellij options --layout-dir [LAYOUR_DIR]`
- `layout_dir: [LAYOUT_DIR]`
* add option `theme` that allows for setting of a theme,
the default is `default`
* under `themes` the themes can be described as follows:
either:
```
themes:
default:
fg: [0,0,0]
bg: [0,0,0]
black: [0,0,0]
red: [0,0,0]
green: [0,0,0]
yellow: [0,0,0]
blue: [0,0,0]
magenta: [0,0,0]
cyan: [0,0,0]
white: [0,0,0]
orange: [0,0,0]
```
or
```
themes:
default:
fg: 0
bg: 0
black: 0
red: 0
green: 0
yellow: 0
blue: 0
magenta: 0
cyan: 0
white: 0
orange: 0
```
If the key is different from default, it needs to either be specified on
start with `options --theme [THEME]`, or in the configuration file under
theme: [THEME].
closes#390
* refactor(fakes): clean up add_terminal_input
* refactor(fakes): append whole buf to output_buffer in FakeStdoutWriter::write
* refactor(fakes): append whole buf to output_buffer in FakeInputOutput::write_to_tty_stdin
* fix(fakes): allow partial reads in read_from_tty_stdout
This patch fixes two bugs in read_from_tty_stdout:
* if there was a partial read (ie. `bytes.read_position` is not 0 but
less than `bytes.content.len()`), subsequent calls to would fill `buf`
starting at index `bytes.read_position` instead of 0, leaving range
0..`bytes.read_position` untouched.
* if `buf` was smaller than `bytes.content.len()`, a panic would occur.
* refactor(channels): use crossbeam instead of mpsc
This patch replaces mpsc with crossbeam channels because crossbeam
supports selecting on multiple channels which will be necessary in a
subsequent patch.
* refactor(threadbus): allow multiple receivers in Bus
This patch changes Bus to use multiple receivers. Method `recv` returns
data from all of them. This will be used in a subsequent patch for
receiving from bounded and unbounded queues at the same time.
* refactor(channels): remove SenderType enum
This enum has only one variant, so the entire enum can be replaced with
the innards of said variant.
* refactor(channels): remove Send+Sync trait implementations
The implementation of these traits is not necessary, as
SenderWithContext is automatically Send and Sync for every T and
ErrorContext that's Send and Sync.
* If starting in the locked mode after the merge,
the locked mode seems to need 2 actions to go to
the normal mode - after that everything works
as expected.
- This is not intended.
* refactor(os_input_output): use Pid for child process
* fix(debug): change debug_to_file to write &[u8]
This patch changes debug_to_file to write entire slices in one call, to
avoid the overhead of opening and closing files for each byte written.
* refactor(ServerOsApi): remove unnecessary muts from methods
Co-authored-by: KOVACS Tamas <ktamas@fastmail.fm>
* The setup subcommand was exiting the programm no matter what
even if the `clean` flag was provided.
Now it returns to the
main function on encountering the clean flag.