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

cwd is lost when opening new pane with nushell #3068

Closed
n8henrie opened this issue Jan 17, 2024 · 2 comments
Closed

cwd is lost when opening new pane with nushell #3068

n8henrie opened this issue Jan 17, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@n8henrie
Copy link

2. Issues with the Zellij UI / behavior / crash

Issue description

I am new to zellij and nushell both, so I apologize with my lack of familiarity with the territory.

In zellij, with my default_shell set to nushell, when I open a new pane, the new pane opens to my home directory instead of staying in the cwd, as expected after #691

If I change my default shell to bash, the pane opens into cwd as expected.

Minimal reproduction

> echo $env.NU_VERSION
0.88.1
> cd (mktemp -d)
> pwd
/private/tmp/tmp.f8WsBgKlrW
> # <C-p> n
> # in the new pane:
> pwd
/Users/n8henrie
@n8henrie n8henrie added the bug Something isn't working label Jan 17, 2024
@cristiand391
Copy link
Contributor

I can't repro on this using nu 0.89.0 and zellij 0.39.2

a few questions:

  1. what version of zellij are you using? zellji --version
  2. do you have nushell in your PATH and set default_shell to nu or set default_shell to the path to the nu bin?
  3. can you repro with zsh/bash?

@n8henrie
Copy link
Author

Thanks for chiming in! Your comment that it worked for you prompted me to keep digging, and I can confirm that it is a problem specific to my environment. Specifically, I had configured my default_shell to be a script that first prepares some environment variables and then enters nu; clearly something about this messes up the PWD retention. Once I change default_shell to be the path to the nu binary directly, the behavior is normal.

Sorry for the false alarm issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants