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

Add action QueryTabNames to list all tab names #2145

Merged
merged 43 commits into from
Mar 1, 2023

Conversation

naosense
Copy link
Contributor

@naosense naosense commented Feb 8, 2023

To resolve #2098 , as shown below
image

@naosense naosense temporarily deployed to cachix February 8, 2023 07:09 — with GitHub Actions Inactive
zellij-server/src/lib.rs Outdated Show resolved Hide resolved
zellij-client/src/lib.rs Outdated Show resolved Hide resolved
@naosense naosense temporarily deployed to cachix February 8, 2023 09:16 — with GitHub Actions Inactive
@naosense naosense marked this pull request as ready for review February 8, 2023 09:16
@naosense naosense temporarily deployed to cachix February 14, 2023 08:30 — with GitHub Actions Inactive
@naosense naosense temporarily deployed to cachix February 20, 2023 06:17 — with GitHub Actions Inactive
@naosense naosense temporarily deployed to cachix February 20, 2023 06:20 — with GitHub Actions Inactive
@imsnif
Copy link
Member

imsnif commented Feb 20, 2023

Hey @naosense - what's the status of this PR?

@naosense
Copy link
Contributor Author

I think it's ready for review

Copy link
Member

@imsnif imsnif left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work @naosense - also thanks for taking care of the merge conflict.

I left some comments about naming, and otherwise - can we maybe add a test for this? Preferably one that tests the entire flow with the cli action. I think there are a few examples in tab_integration_tests.

zellij-client/src/lib.rs Outdated Show resolved Hide resolved
zellij-server/src/lib.rs Outdated Show resolved Hide resolved
@naosense
Copy link
Contributor Author

I left some comments about naming, and otherwise - can we maybe add a test for this? Preferably one that tests the entire flow with the cli action. I think there are a few examples in tab_integration_tests.

after i read tab_integration_tests, i didnt find similar test. i want to run a command zellij action query-tab-names, then test the snapshot, but i cant figure out how to run cmd. Am i in the right direction?

@imsnif
Copy link
Member

imsnif commented Feb 21, 2023

Sorry @naosense - I meant this file, my mistake: https://github.com/zellij-org/zellij/blob/main/zellij-server/src/unit/screen_tests.rs#L989

Just be aware that you'll need to adjust your test a little bit, since the normal snapshot probably won't help you here (as it's taking a snapshot of the render and not the new log).

imsnif and others added 23 commits March 1, 2023 15:49
* fix(layout): tab focus

* style(fmt): rustfmt
…g#2198)

* fix(cli): the new-tab action now also searches for layouts in the layout dir

* style(fmt): rustfmt

* fix(tests): add missing parameter to cli action
…#2200)

* fix(themes): missing tokyo-night-dark theme

* fix(kdl): new-tab keybind also looks in layout_dir for layouts
* fix(cli): properly set cwd for edit panes

* fix(layouts): properly set cwd for edit panes

* style(fmt): rustfmt
* fix(layouts): do not relayout twice on auto_layout

* style(fmt): rustfmt
* fix(cli): take default shell from config if it exists when opening new tab

* fix(cli): take layout dir from config when opening new tab if it exists

* style(fmt): rustfmt
* style(fmt): remove warnings

* fix(swap-layouts): introduce exact panes constraint

* fix(swap-layouts): improve floating pane swap layout ux

* style(fmt): rustfmt
* fix(sixel): report pixel size in winsize change ioctl

* style(fmt): rustfmt
@imsnif imsnif temporarily deployed to cachix March 1, 2023 15:46 — with GitHub Actions Inactive
@imsnif imsnif temporarily deployed to cachix March 1, 2023 15:48 — with GitHub Actions Inactive
@imsnif imsnif merged commit c2fb275 into zellij-org:main Mar 1, 2023
naosense added a commit to naosense/zellij that referenced this pull request Mar 2, 2023
…rg#2145)

* extend display char in tab

* Add action to list all tab names

* print tab names and remove logs

* change msg name, and handle Log in normal client

* fix log

* resolve code conflict

* change var name

* add snapshot test

* fix failed test case

* restore snapshot

* Revert "restore snapshot"

This reverts commit b97a951.

* restore snapshot

* revert snapshot

* fix(layout): various parser and ui fixes (zellij-org#2191)

* fix(layout): error on nodes outside layout node

* fix(layout): move stacked property to pane

* fix(layout): various stack exceptions

* fix(ui): non-flexible stacked pane titles now take up their full length

* fix(ui): stack titles with no-pane-frames take up their proper length

* style(fmt): rustfmt

* docs(changelog): layout fixes

* fix(messaging): cache hold pane messages by their tab_id if the tab is not ready (zellij-org#2196)

* fix(messaging): cache hold pane messages by their tab_id if the tab is not ready

* style(fmt): rustfmt

* docs(changelog): open panes fix

* fix(layout): tab focus (zellij-org#2197)

* fix(layout): tab focus

* style(fmt): rustfmt

* docs(changel0g): tab focus fix

* fix(cli): new-tab now also looks in layout_dir for layouts (zellij-org#2198)

* fix(cli): the new-tab action now also searches for layouts in the layout dir

* style(fmt): rustfmt

* fix(tests): add missing parameter to cli action

* docs(changelog): new-tab cli layout folder fix

* fix(kdl): new-tab keybind looks in layout_dir for layouts (zellij-org#2200)

* fix(themes): missing tokyo-night-dark theme

* fix(kdl): new-tab keybind also looks in layout_dir for layouts

* docs(changelog): new-tab keybind layout folder fix

* fix(cli): edit cwd (zellij-org#2201)

* fix(cli): properly set cwd for edit panes

* fix(layouts): properly set cwd for edit panes

* style(fmt): rustfmt

* docs(changelog0

* fix(layouts): do not relayout twice on auto_layout (zellij-org#2202)

* fix(layouts): do not relayout twice on auto_layout

* style(fmt): rustfmt

* fix(new-tab): get config parameters from config file (zellij-org#2203)

* fix(cli): take default shell from config if it exists when opening new tab

* fix(cli): take layout dir from config when opening new tab if it exists

* style(fmt): rustfmt

* docs(changelog): new-tab config parameters

* fix(grid): only use background pending styling when deleting characters (zellij-org#2204)

* docs(changelog): neovim underline fix

* feat(layouts): exact panes constraint (zellij-org#2206)

* style(fmt): remove warnings

* fix(swap-layouts): introduce exact panes constraint

* fix(swap-layouts): improve floating pane swap layout ux

* style(fmt): rustfmt

* docs(changelog): exact panes constraint

* fix(pty): report no-cwd for empty path returned from sysinfo (zellij-org#2213)

* fix(sixel): report pixel size in winsize change ioctl (zellij-org#2212)

* fix(sixel): report pixel size in winsize change ioctl

* style(fmt): rustfmt

* docs(changelog): various fixes

* style(code): naming

* test(log): adjust query tab names test to look at the log message

* style(fmt): rustfmt

---------

Co-authored-by: Aram Drevekenin <aram@poor.dev>
Co-authored-by: Jae-Heon Ji <32578710+jaeheonji@users.noreply.github.com>
@naosense naosense deleted the list_tab_names_2 branch March 2, 2023 06:48
joshheyse pushed a commit to joshheyse/zellij that referenced this pull request Mar 11, 2023
…rg#2145)

* extend display char in tab

* Add action to list all tab names

* print tab names and remove logs

* change msg name, and handle Log in normal client

* fix log

* resolve code conflict

* change var name

* add snapshot test

* fix failed test case

* restore snapshot

* Revert "restore snapshot"

This reverts commit b97a951.

* restore snapshot

* revert snapshot

* fix(layout): various parser and ui fixes (zellij-org#2191)

* fix(layout): error on nodes outside layout node

* fix(layout): move stacked property to pane

* fix(layout): various stack exceptions

* fix(ui): non-flexible stacked pane titles now take up their full length

* fix(ui): stack titles with no-pane-frames take up their proper length

* style(fmt): rustfmt

* docs(changelog): layout fixes

* fix(messaging): cache hold pane messages by their tab_id if the tab is not ready (zellij-org#2196)

* fix(messaging): cache hold pane messages by their tab_id if the tab is not ready

* style(fmt): rustfmt

* docs(changelog): open panes fix

* fix(layout): tab focus (zellij-org#2197)

* fix(layout): tab focus

* style(fmt): rustfmt

* docs(changel0g): tab focus fix

* fix(cli): new-tab now also looks in layout_dir for layouts (zellij-org#2198)

* fix(cli): the new-tab action now also searches for layouts in the layout dir

* style(fmt): rustfmt

* fix(tests): add missing parameter to cli action

* docs(changelog): new-tab cli layout folder fix

* fix(kdl): new-tab keybind looks in layout_dir for layouts (zellij-org#2200)

* fix(themes): missing tokyo-night-dark theme

* fix(kdl): new-tab keybind also looks in layout_dir for layouts

* docs(changelog): new-tab keybind layout folder fix

* fix(cli): edit cwd (zellij-org#2201)

* fix(cli): properly set cwd for edit panes

* fix(layouts): properly set cwd for edit panes

* style(fmt): rustfmt

* docs(changelog0

* fix(layouts): do not relayout twice on auto_layout (zellij-org#2202)

* fix(layouts): do not relayout twice on auto_layout

* style(fmt): rustfmt

* fix(new-tab): get config parameters from config file (zellij-org#2203)

* fix(cli): take default shell from config if it exists when opening new tab

* fix(cli): take layout dir from config when opening new tab if it exists

* style(fmt): rustfmt

* docs(changelog): new-tab config parameters

* fix(grid): only use background pending styling when deleting characters (zellij-org#2204)

* docs(changelog): neovim underline fix

* feat(layouts): exact panes constraint (zellij-org#2206)

* style(fmt): remove warnings

* fix(swap-layouts): introduce exact panes constraint

* fix(swap-layouts): improve floating pane swap layout ux

* style(fmt): rustfmt

* docs(changelog): exact panes constraint

* fix(pty): report no-cwd for empty path returned from sysinfo (zellij-org#2213)

* fix(sixel): report pixel size in winsize change ioctl (zellij-org#2212)

* fix(sixel): report pixel size in winsize change ioctl

* style(fmt): rustfmt

* docs(changelog): various fixes

* style(code): naming

* test(log): adjust query tab names test to look at the log message

* style(fmt): rustfmt

---------

Co-authored-by: Aram Drevekenin <aram@poor.dev>
Co-authored-by: Jae-Heon Ji <32578710+jaeheonji@users.noreply.github.com>
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.

List opened tabs in a session?
3 participants