Issue #10032 open

Optionally disable diff on specific files in a pull request (BB-11005)

stephen mathieson
created an issue

We've got a few repositories which keep "built" css and javascript files checked in. We need to check these files in so our package manager (component) is able to access them at install-time, rather than forcing it to pre-process our stylesheets/templates (stylus, less, jade, whatever).

My request is that we can somehow tell the pull request view (https://bitbucket.org/user/repo/pull-request/XYZ/) to not display a diff on a few specific files. This could be a setting at the "Create pull request" step, the repository settings panel.. anywhere, really. This would make code reviews significantly easier and much faster.

An example repo structure would look like this:

$ tree
.
├── Makefile
├── Readme.md
├── cache.js
├── component.json
├── example.html
├── index.js
├── package.json
├── style.css # ignore diff
├── style.styl # show diff
├── template.jade # show diff
├── template.js # ignore diff
├── test
│   ├── cache.js
│   ├── generator.js
│   └── index.html
└── test-server.pid

Comments (33)

  1. Jeff Clark

    Some files updated by development tools are re-generated or re-scaffolded but are not of value to a code review / pull request. This would be a great feature; please tell your friends to vote for it.

  2. Tom Worster

    composer.lock, js and css files generated by build script, combined, and combined+minified, plus their source maps, they all need to be in the repo but it makes no sense to display them in a commit or PR diff. indeed, Bitbucket's client script for displaying the diffs typically gives up because of these "object" files that ire irrelevant to code review

  3. Jeffrey Labonski

    +1

    npm's package-lock.json is a utter mess of noise in a PR. Must be checked in, can't be meaningfully reviewed. Man, it'd be great to have some clickable HIDDEN icons next to the file list and hide the diff's div by default.

  4. Daniel Walz

    +1 Using C++/JUCE where many files are autogenerated. We don't want the project generator to be installed on every developers machines, hence we put the generated code in source control. Hiding certain files or folder would be really helpful (maybe not necessarily hiding it, but having them collapsed, so the meaningful diffs could be easier spotted.)

  5. Log in to comment