Giter Club home page Giter Club logo

Comments (6)

xitonix avatar xitonix commented on May 18, 2024 2

Thank you for getting back to me so quickly @jedib0t . I tried the workaround you suggested and it worked perfectly. Thanks a lot mate.

Btw, what I said was not just a complement! That's a beautiful piece of work buddy. Good on ya!

from go-pretty.

jedib0t avatar jedib0t commented on May 18, 2024 1

Yeah I have a fix in the pipeline for this. Give me a day or two. See if you can use the commit hash instead of the version tag.

from go-pretty.

jedib0t avatar jedib0t commented on May 18, 2024

Hey thanks for the compliments. My first open-source project, so I'm a little attached to it at the moment. 😄

Found the bug b.t.w, your custom transformer is returning Bold text which looks like this with escape sequences: �[1m10000�[0m. The code then applies the style's formatter for the footer which is text.FormatUpper which converts the case-sensitive escape sequences too: �[1M10000�[0M. And this is basically garbage to the terminal emulator. I'm guessing the same bug should be show up in headers too if you use TransformerHeader.

I'll fix it this week. 👍

But if you can't wait for a fix until then, you can use this workaround before calling t.Render():

    t.Style().Format.Footer = text.FormatDefault

from go-pretty.

jedib0t avatar jedib0t commented on May 18, 2024

@xitonix Thanks for reporting the bug btw. I appreciate it!

from go-pretty.

jedib0t avatar jedib0t commented on May 18, 2024

Hey @xitonix the latest code in master branch has the fix (d24d83b, 8b58fba). I'll cut a tag by end of week.

Out of curiosity, do you use go mod or dep for dependency management? I transitioned to go mod some time back, but I figured recently that I've not done major versioning the way go mod likes it. I can fix that, but that may break dep support.

from go-pretty.

xitonix avatar xitonix commented on May 18, 2024

Hey mate. I do use go mod, but because of the reason you mentioned yourself above, it cannot pick up the right version unfortunately. But I don't really understand why go mod always fetches v4.3.0 while you don't even have a v4 branch, even though I explicitly asked for v5.0.1! This is what appears in my go.mod file after I run:

go get github.com/jedib0t/[email protected]

github.com/jedib0t/go-pretty v4.3.0+incompatible

from go-pretty.

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.