params/metrics: diff: implement tabulated markdown output (--show-md)#3757
Merged
Conversation
skshetry
commented
May 8, 2020
| "speedcopy>=2.0.1; python_version < '3.8' and sys_platform == 'win32'", | ||
| "flatten_json>=0.1.6", | ||
| "texttable>=0.5.2", | ||
| "tabulate>=0.8.7", |
Collaborator
Author
There was a problem hiding this comment.
This does not support aligning headers. It does have colalign but it aligns the whole column, and, I don't think it's a deal-breaker.
pmrowla
approved these changes
May 8, 2020
Contributor
|
@skshetry thank you for making the changes! |
skshetry
commented
May 11, 2020
| for path in paths: | ||
| rows.append([status, path]) | ||
|
|
||
| return table(["Status", "Path"], rows, True) |
Collaborator
Author
There was a problem hiding this comment.
Should the output's column be swapped?
| Path | Status |
|---|---|
| model.pkl | Added |
Collaborator
Author
There was a problem hiding this comment.
^ and also capitalized?
Contributor
There was a problem hiding this comment.
Should the output's column be swapped?
Currently, it is in the order in which it was requested. And, which matches git status.
^ and also capitalized?
not capitalized because it was requested in that form and matches git status.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Via
--show-mdondiffs.❗ I have followed the Contributing to DVC checklist.
📖 If this PR requires documentation updates, I have created a separate PR (or issue, at least) in dvc.org and linked it here. If the CLI API is changed, I have updated tab completion scripts.
treeverse/dvc.org#1266
Thank you for the contribution - we'll try to review it as soon as possible. 🙏
dvc diff --show-md.The
dvc params diffand similar commands would output header centered. With this change, it will be left-aligned.Previously:
Now:
^ Same output in markdown parsed by Github:
Resolve #3690