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

Fix directory truncation in git repositories with symlinks in path #385

Merged
merged 1 commit into from
Mar 6, 2018

Conversation

AnonymFx
Copy link
Contributor

@AnonymFx AnonymFx commented Mar 4, 2018

Description

When setting SPACESHIP_DIR_TRUNC to true, only the root of the repository was show if the path to the directory contained symlinks.
Adding the -P option to the pwd call (avoid all symlinks) fixes this.

In the example below, 'Projects' is the symlink.

Screenshot

Before:
Before

After:
After

Copy link
Member

@salmanulfarzy salmanulfarzy left a comment

Choose a reason for hiding this comment

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

Bug confirmed and PR fixes it. Good catch @AnonymFx

@salmanulfarzy salmanulfarzy added bug Bug related to code base, behavior, displaying, etc. improvement A PR that make small changes for improving UX, performance, readability, etc labels Mar 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug related to code base, behavior, displaying, etc. improvement A PR that make small changes for improving UX, performance, readability, etc
Development

Successfully merging this pull request may close these issues.

None yet

3 participants