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

Extend documentation for bash #2006

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

foursixnine
Copy link

@foursixnine foursixnine commented May 18, 2019

When using a system that is updated frequently the user could find the situation where the path to the repository root has changed but the python binary is looking somewhere else (e.g, Python gets an upgrade from 3.6 to 3.7) or if the same bashrc is shared among different machines with different versions of python (2.x, 3.x and so on), is useful to be able to get one consistent way to figure out
what would be the path.

Let me know if changes are needed :) (Or if there's a better place to mention that trick)

When using a system that is updated frequently the user could find the situation where the path to the repository root has changed
but the python binary is looking somewhere else (e.g, Python gets an upgrade from 3.6 to 3.7) or if the same bashrc is shared among 
different machines with different versions of python (2.x, 3.x and so on), is useful to be able to get one consistent way to figure out
what would be the path.
@PH111P
Copy link
Member

PH111P commented May 18, 2019

I really like this trick, however, as far as I understand it, it only works for local (per user) installations of the powerline. For global installations, PYTHON_SITE_PATH=$(python -c "import site; print(site.getsitepackages()[0])") should do the trick.

Slightly unrelated, for users of fish, the commands should look like

set PYTHON_SITE_PATH (python -c "import site; print(site.getsitepackages()[0])")
source "$PYTHON_SITE_PATH/powerline/bindings/fish/powerline-setup.fish"

@foursixnine
Copy link
Author

@PH111P I just realized that the wording is a bit confusing... Will improve it soonish.

Anything else needed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants