Comments (4)
@jlunaq Apologies for the late reply. I am busy at the moment with a lot of things. If you do not mind, I would like to keep it open. My idea would be another reporter type, one that is using Go templates to create the report output. This way it would be generic enough to create HTML, or JSON, or Markdown style reports. However, I cannot really say when I find time for an implementation. PRs are always welcome, too.
from dyff.
Yes, definitely. I wrote the package in such a way that it would be possible to just use the difference detection part as a library. Besides dyff
itself, there are at least two other projects I know that use it as a library. That being said, it sure could use a bit refactoring/restructuring to be a bit more convenient. Let me know if there is something unclear or could be done better.
Main entry point is: github.com/homeport/dyff/pkg/dyff.CompareInputFiles()
. This takes in ytbx.InputFile
s and optional compare options, for example to ignore order changes in lists. The github.com/gonvenience/ytbx.InputFile
is mostly there due to the fact that you need support for files with multiple documents and different input sources (local file, remote file, or stdin). You get that with ytbx.LoadFile()
.
from dyff.
Thanks @HeavyWombat. I already looked at the tests and they give me a clue about how to use it as a library. I think I have no problem with that at all. Could you please only let me know how can I customize the report to be an html table instead?, I can be working on a fork and submit a PR if that works for you.
from dyff.
No worries. I thought I required that feature, but my team told me it wasn't really needed. However, if I plan to implement it in the future, I will let you know. Please keep this open
from dyff.
Related Issues (20)
- Exclude based on value HOT 1
- Configure listItemIdentifierCandidates via settings HOT 5
- used as a library HOT 2
- dyff stutters when diffing some multiline documents HOT 8
- interaction between regular expressions and YAML path segments is unclear HOT 2
- Replace `github.com/gorilla/mux` package HOT 2
- Truncate/Filter Diff Output HOT 6
- [bug] Wrong version in latest release HOT 2
- contribute a new language model to highlight.js / github's linguist HOT 1
- Restore release of Windows binaries HOT 1
- Ability to exclude additions
- Retain color codes when piped? HOT 1
- No documentation for format of --exclude and --include options HOT 1
- `dyff yaml` incorrectly converts boolstring to bool HOT 1
- Comment breaks yaml output
- Tab completion HOT 5
- Support outputting "between" to yaml
- feature request: Bring in some diff options: ignore-all-space, recursive, brief HOT 1
- Feature request: aarch64/arm64 binaries HOT 2
- Feature request: GitHub markdown compatible diffs HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dyff.