Skip to content

Show relative path in peek #261

@finalpatch

Description

@finalpatch

Right now lsp-ui-peek shows full path, so the file name part is usually truncated by the window border. I can only see the first half of the path to every file, which are all identical, and doesn't provide any value.

I suggest change this to show path relative to project root. This will make the path a lot more useful and waste less space.

Activity

finalpatch

finalpatch commented on Mar 27, 2019

@finalpatch
Author

Or at least provide a customize option to show relative path

yyoncho

yyoncho commented on Mar 30, 2019

@yyoncho
Member

are the files under the current project root?

finalpatch

finalpatch commented on Mar 31, 2019

@finalpatch
Author

Yes they are in a git repository, which is considered a project root. I don't use projectile though.

c02y

c02y commented on Jan 20, 2022

@c02y

I think relative path is not enough, for example, I'm using Rust, the path in the peek would be something like

/home/user/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/time.rs

The path is so long, when I use multiple windows in one frame, I only see a small part of it, I have to maximize the current window to get the full path. But I only care about the head and tail parts.

tonicebrian

tonicebrian commented on Jul 18, 2023

@tonicebrian

Does someone has a solution for this?

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @tonicebrian@finalpatch@c02y@yyoncho@brotzeit

        Issue actions

          Show relative path in peek · Issue #261 · emacs-lsp/lsp-ui