GithubHelp home page GithubHelp logo

Comments (2)

lkhphuc avatar lkhphuc commented on June 16, 2024 1

On the topic, does any find the default truncation of path to no more than 3 directories a little bit excessive?
Though I don't think dynamic truncation is possible with lualine at the moment.

from lazyvim.

dpetka2001 avatar dpetka2001 commented on June 16, 2024 1

Not excessive for me, but that's purely personal preference from my part.

You could still just copy the pretty_path function and make it look like you want.

Or we could add a trunc_level variable and check if it's, for example, 0, then don't do any truncating. We could also do the truncating based on the trunc_level. For example, if trunc_level = 5, then we could just unpack the parts table based on the trunc_level.

But again that begs the question of how a user would like to see it. Would he want to see the first 2 parts of the path, then the ellipses character and the last 3 parts at the end. Or would it be a 1 and 4 split? Or a 3 and 2 split?

This complicates the logic unnecessarily I believe and should be better left to the user to implement a similar function in their personal configuration and use that function in their lualine component to make it look exactly how they like.

from lazyvim.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.