diff --git a/common/config_list.inc b/common/config_list.inc index efccbe182ca0..ccece852c8a4 100644 --- a/common/config_list.inc +++ b/common/config_list.inc @@ -20,6 +20,7 @@ core.package_id:default_non_embed_mode: By default, 'minor_mode' core.package_id:default_python_mode: By default, 'minor_mode' core.package_id:default_unknown_mode: By default, 'semver_mode' + core.scm:excluded: List of excluded patterns for builtin git dirty checks core.sources:download_cache: Folder to store the sources backup core.sources:download_urls: List of URLs to download backup sources from core.sources:exclude_urls: URLs which will not be backed up diff --git a/reference/conanfile/attributes.rst b/reference/conanfile/attributes.rst index fb4ddc8d61f1..f735f3d958e8 100644 --- a/reference/conanfile/attributes.rst +++ b/reference/conanfile/attributes.rst @@ -118,6 +118,13 @@ be computed. It can take three different values: approach allows multiple `conanfile.py` files to exist within the same Git repository, with each file exported under its distinct revision. +When ``scm`` or ``scm_folder`` is selected, the Git commit will be used, but by default +the repository must be clean, otherwise it would be very likely that there are uncommitted +changes and the build wouldn't be reproducible. So if there are dirty files, Conan will raise +an error. If there are files that can be dirty in the repo, but do not belong at all to the +recipe or the package, then it is possible to exclude them from the check with the ``core.scm:excluded`` +configuration, which is a list of patterns (fnmatch) to exclude. + upload_policy