Giter Site home page Giter Site logo

Pipe (stdout) mode adds newline about croc HOT 4 CLOSED

fungs avatar fungs commented on May 28, 2024
Pipe (stdout) mode adds newline

from croc.

Comments (4)

schollz avatar schollz commented on May 28, 2024

happy to accept a PR for this, probably only need to change Println to Print

from croc.

fungs avatar fungs commented on May 28, 2024

Probably, maybe, I don't know. I'm not using the software, just tested it for understanding and stumbled over this obvious bug.

from croc.

TravisRoad avatar TravisRoad commented on May 28, 2024

https://github.com/schollz/croc/blob/ce91e3b420b47d26ea0c3c9d40e437b714c70e2d/src/croc/croc.go#L1087C1-L1102C3

I've identified the issue occurring at line 1101 in src/croc/croc.go. When the Stdout option is set to true, the code logic in this segment necessitates the deletion of the corresponding file and the output of a newline character at the end. It appears that this additional newline character is causing the problem. In my opinion, it would be more appropriate to direct the newline character output to os.Stderr in this context.

from croc.

TravisRoad avatar TravisRoad commented on May 28, 2024

IMO, this issue can be closed.

from croc.

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.