darrenburns / dunk

Prettier git diffs in the terminal 🎨
745 stars 15 forks source link

Refactor for use in other Python tools? #1

Open ewels opened 2 years ago

ewels commented 2 years ago

This tool looks amazing 🤩

Any chance of a slight refactor so that I can import it into my tool and use it to render diffs that I already have as strings? At the moment it looks like the stdin is hard-coded..

darrenburns commented 2 years ago

Thanks! 😄

Yes, I'll be refactoring (probably quite extensively) to enable support for things like this after I've finalised the output format and handled some edge cases and missing output.

ewels commented 2 years ago

Excellent stuff! 👏🏻 Getting my requests in early! 😅 Let me know if a PR would be useful (I guess not at this stage assuming you have big plans already).

I've used Delta for a while, but never been able to use it within tools as it's not a Python package. Excited to have a play with Dunk 😁