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

Installing navi correctly on MacOS for .zsh #777

Open
AnvarAtayev opened this issue Aug 12, 2022 · 9 comments
Open

Installing navi correctly on MacOS for .zsh #777

AnvarAtayev opened this issue Aug 12, 2022 · 9 comments

Comments

@AnvarAtayev
Copy link

I am just wondering if I have installed navi correctly.

I am using macOS Monterey 12.5 and installed navi using homebrew via brew install navi.
To install the shell widget, I pasted the following into the end of my .zshrc file:

# zsh
eval "$(navi widget zsh)"

(I do not have a .bshrc file, and thought this was the alternative).

Having done the above step, I am now able to use navi by calling Ctrl + G as expected.

Entering navi fn welcome and entering the config command, I get a permission denied error.
Screenshot 2022-08-12 at 11 30 52
Screenshot 2022-08-12 at 11 32 23

I'm not sure how to overcome this. Also, I am noticing that it is trying to use bash instead of zsh. Not sure how to change this also.

Any help would be appreciated.

@welcome
Copy link

welcome bot commented Aug 12, 2022

Thanks for opening your first issue here! In case you're facing a bug, please update navi to the latest version first. Maybe the bug is already solved! :)

@wiegell
Copy link

wiegell commented Aug 14, 2022

same on armbian, related? #777

@jjournet
Copy link

I have the same issue on MacOS Monterey (M1), and I think the problem is related to the hardcoded path of the config file containing a space, and not handled correctly by navi
2 things:

  • it would be better for navi to rely on a default config file system-wide when no config at user level (so that we can change the location of the config file), for instance in /etc/navi
  • the default config file should be in ~/.config/navi , not in Library (IMHO)

@jjournet
Copy link

I would say issue was introduced in change #518
I don't code in Rust, so I can't propose a fix

@jjournet
Copy link

jjournet commented Oct 18, 2022

Actually, in the current version, it's not working on Mac, because you can't have a config file (Navi doesn't find it because of the space), the checkout of new libraries works (I was able to get the defaults cheats), but navi doesn't see them
(I was using an older version until recently when I switched to brew)

@jjournet
Copy link

I was wrong, actually version 2.19 is working fine with the path, sticking to this one for now, but:

  • older version, so does not contains all fixes/feature
  • doesn't provide arm64 exe for mac silicon

@dmartzol
Copy link

dmartzol commented Nov 1, 2022

the default config file should be in ~/.config/navi, not in Library (IMHO)

+1

Most CLI apps have the config in ~/.config. Having the config file in a different location just makes dotfiles management more difficult, IMHO

@denisidoro
Copy link
Owner

The config dir is defined by https://crates.io/crates/directories-next

Changing it now would be a breaking change :/

@denisidoro
Copy link
Owner

denisidoro commented Apr 9, 2023

I'm trying to understand if the problem is really with the space. Could you provide more logs / evidence?

"permission denied" seems to be unrelated to spaces

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

No branches or pull requests

5 participants