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

Support install without sudo permissions? #51

Closed
quadebroadwell opened this issue Sep 23, 2019 · 5 comments · Fixed by #106
Closed

Support install without sudo permissions? #51

quadebroadwell opened this issue Sep 23, 2019 · 5 comments · Fixed by #106
Labels
easy Good for newcomers new feature New feature or request

Comments

@quadebroadwell
Copy link

Is it possible to have an install route without the need for sudo?

@welcome
Copy link

welcome bot commented Sep 23, 2019

Thanks for opening your first issue here!

@denisidoro
Copy link
Owner

The install script simply creates a symlink in /usr/bin. Without sudo, it could create in another folder, but I'm not sure what's the best choice. Any ideas?

@denisidoro denisidoro added new feature New feature or request easy Good for newcomers labels Sep 24, 2019
@UchihaSR
Copy link

shall i take this issue?

@denisidoro
Copy link
Owner

@UchihaSR feel free! But I still don't know what path we should use in this case

denisidoro added a commit that referenced this issue Oct 2, 2019
Thanks for making this project, it's really cool! I'd been looking for something like this for a while.
I noticed that your shell widget is pretty much stand-alone and I wanted to be able to use navi directly as an [oh-my-zsh][1] plugin, so I added a few things to the widget and moved it to the root of the repository so that the repo can be cloned straight into the `plugins` folder and detected when added in the plugin array.

I think it should be similarly simple with `fish`, but I'm not too familiar with that shell, so I'll leave it to someone else. The `navi.plugin.zsh` file should still be sourcable as a widget for people not using oh-my-zsh, so technically the `shell/` directory could be removed and `navi widget`updated to use the new file.

## What's included
- oh-my-zsh plugin
- install documentation
- no PATH modification required when used with OMZ
- Added bonus: #51 is kind of unofficially addressed by this (assuming one uses OMZ)

## Future Work
- Pre-filter using `$BUFFER` when hitting `Alt+G` to get something similar to `navi query`
- Update `navi widget zsh` to use `navi.plugin.zsh`

Let me know what you think. I'm working on a few cheatsheets, and will open PRs for those as they become ready.

Cheers,
Alex

[1]: https://github.com/robbyrussell/oh-my-zsh
@alxbl
Copy link
Contributor

alxbl commented Oct 2, 2019

@quadebroadwell if you use oh-my-zsh, checkout the PR that I submitted yesterday, it will let you use navi as a widget without having to do a system-wide install.

Alternatively, you can just git clone navi and manually set your PATH to include navi's directory in your dotfiles.

# .zprofile or similar
export PATH="$PATH:/path/to/navi/repo"

You can then manually update using git pull.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
easy Good for newcomers new feature New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants