Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature request: Make 'BUILD' file pattern configurable #4015

Closed
nicks opened this issue Nov 1, 2016 · 3 comments
Closed

feature request: Make 'BUILD' file pattern configurable #4015

nicks opened this issue Nov 1, 2016 · 3 comments

Comments

@nicks
Copy link

nicks commented Nov 1, 2016

Pants uses files with the magic prefix "BUILD". Sadly, some other build systems also use BUILD files.

Would Pants-team accept a patch to make this configurable, so that Pants can co-exist with other BUILD-using systems?

Based on a brief inspection, the pattern is consolidated to a few places, and I think it would be pretty straightforward to thread it through from the global pants.ini options.

@jsirois
Copy link
Contributor

jsirois commented Nov 1, 2016

Sounds reasonable to me.

@stuhood
Copy link
Sponsor Member

stuhood commented Nov 1, 2016

@nicks : It should be possible to accomplish this with existing options by suffixing all of pants BUILD files (ie, as BUILD.pants), and then setting the build-ignore option in pants.ini to something that will cause unsuffixed BUILD files to be ignored:

$ ./pants help-advanced | grep -A3 'build-ignore='
--build-ignore=<str> (--build-ignore=<str>) ..., --build-ignore="[<str>, <str>, ...]", --build-ignore="+[<str>, <str>, ...]" (@fromfile value supported) (default: ['.*','/dist/','bower_components','node_modules','*.egg-info'])
    Paths to ignore when identifying BUILD files. This does not affect any other
    filesystem operations. Patterns use the gitignore pattern syntax (https
    ://git-scm.com/docs/gitignore).

@nicks
Copy link
Author

nicks commented Nov 2, 2016

@stuhood brilliant! that works for me.

@nicks nicks closed this as completed Nov 2, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants