microsoft / beachball

The Sunniest Semantic Version Bumper
https://microsoft.github.io/beachball
MIT License
696 stars 85 forks source link

Add the ability to ignore certain files #135

Open kenotron opened 4 years ago

kenotron commented 4 years ago

Should we have a .beachballignore file or maybe an entry in the package.json like we already have?

kenotron commented 4 years ago

I think we should target reusing the beachball key in the package.json. This way we avoid adding more config files around for now. We can think more holistically about config in another change.

lynamemi commented 4 years ago

Hey @kenotron ! Was thinking about this one recently. Is this something I can help with? What does this entail:

target reusing the beachball key in the package.json

kenotron commented 4 years ago

I made beachball check to no longer barf on uncommitted files... does that address your needs?

lynamemi commented 4 years ago

The original need was to make it so PRs with just Markdown files edited could be merged in without change files (and associated build errors) so I don't think so.

kenotron commented 4 years ago

So the part you're looking for is something inside getChangedPackages.

lynamemi commented 4 years ago

Ok cool, I'll take a look.

lynamemi commented 4 years ago

Looks like something like this might work? Although given this is an open source library and not in OUIFR, probably a bad idea to bake this in, which probably brings us back to a .beachballignore file. Thoughts?

function getAllChangedPackages(branch: string, cwd: string) {
  ...
  const ignoredFiles = ['CHANGELOG.md', 'CHANGELOG.json', '*.md'];
  ...
}
dpouliot commented 3 years ago

On the one year anniversary since the last comment, I'd like to add my vote for this feature! We have .stories.jsx and docs.mdx files that are triggering changes; it would be great if we could skip documentation.