Skip to content

Commit

Permalink
[DevTools] Disable sizeBot on DevTools Rull Request (facebook#21885)
Browse files Browse the repository at this point in the history
* [DevTools] Disable sizeBot on DevTools Rull Request

Because DevTools code doesn't affect production bundle size.
Meaningless sizeBot comment give us frastration within Pull Request discussion.

* Revert "[DevTools] Disable sizeBot on DevTools Rull Request"

This reverts commit a43aab9.

* check whether devtools package file only committed
  • Loading branch information
ryota-murakami authored Aug 2, 2021
1 parent d1a58da commit d3f8747
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions dangerfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,17 @@ function row(result) {
return;
}

// Disable sizeBot in a Devtools Pull Request. Because that doesn't affect production bundle size.
const commitFiles = [
...danger.git.created_files,
...danger.git.deleted_files,
...danger.git.modified_files,
];
if (
commitFiles.every(filename => filename.includes('packages/react-devtools'))
)
return;

const resultsMap = new Map();

// Find all the head (current) artifacts paths.
Expand Down

0 comments on commit d3f8747

Please sign in to comment.