tailor icon indicating copy to clipboard operation
tailor copied to clipboard

Add support for querying files in a commit

Open crawford opened this issue 8 years ago • 5 comments

Things to consider:

  • Should the full file be exposed?
  • How are diffs represented?
  • Has the file been added or deleted?

crawford avatar Sep 13 '17 02:09 crawford

Should we also expose helper attributes like Net Additions & Removals?

arithx avatar Sep 13 '17 04:09 arithx

If diffs are represented as a list of additions and a list of removals, the length operator will make that simple. I'm not sure the best way to represent a diff though.

crawford avatar Sep 13 '17 16:09 crawford

In support of checks like "vendor operations must be done in seperate commits" it'd be nice to expose even just the filename in an initial implementation while we wait to figure out how to expose things like diffs, etc.

arithx avatar Sep 13 '17 20:09 arithx

What kinds of behaviors would a diff be useful for? I can't really think of any that seem to fall in the scope of this project. Seems like that is taken care of by the code review part, or any number of other ci/linting tools.

I think it does make sense for lists of added/removed/changed files to be included though, for automated review of vendoring operations. Seems simple enough to just include that in the provided context as lists of each respective operation.

sdemos avatar Sep 22 '17 23:09 sdemos

The idea was to help detect simple changes, for example, if you wanted to make sure that a version string is updated in every location.

crawford avatar Sep 22 '17 23:09 crawford