diff options
author | Nirbheek Chauhan <nirbheek@centricular.com> | 2018-07-02 19:14:09 +0530 |
---|---|---|
committer | Nirbheek Chauhan <nirbheek@centricular.com> | 2018-07-02 19:52:53 +0530 |
commit | d6a9b4cc793707d92055abd4086cf6240bfae1f3 (patch) | |
tree | c4c3845f105bc6bd63c52feeb848a22089ca9655 | |
parent | a1d9adba096589122aefc50fb9429ec0ce0432b9 (diff) | |
download | meson-d6a9b4cc793707d92055abd4086cf6240bfae1f3.zip meson-d6a9b4cc793707d92055abd4086cf6240bfae1f3.tar.gz meson-d6a9b4cc793707d92055abd4086cf6240bfae1f3.tar.bz2 |
Contributing.md: Document procedure for new features [skip ci]
-rw-r--r-- | docs/markdown/Contributing.md | 14 | ||||
-rw-r--r-- | docs/markdown/snippets/feature_new.md | 6 | ||||
-rw-r--r-- | mesonbuild/interpreter.py | 2 |
3 files changed, 18 insertions, 4 deletions
diff --git a/docs/markdown/Contributing.md b/docs/markdown/Contributing.md index 7559c00..e385be2 100644 --- a/docs/markdown/Contributing.md +++ b/docs/markdown/Contributing.md @@ -29,6 +29,20 @@ Do not merge head back to your branch. Any merge commits in your pull request make it not acceptable for merging into master and you must remove them. +## Special procedure for new features + +Every new feature requires some extra steps, namely: + + - Must include a project test under `test cases/`, or if that's not + possible or if the test requires a special environment, it must go + into `run_unittests.py`. + - Must be registered with the [FeatureChecks framework](Release-notes-for-0.47.0.md#Feature_detection_based_on_meson_version_in_project) + that will warn the user if they try to use a new feature while + targetting an older meson version. + - Needs a release note snippet inside `docs/markdown/snippets/` with + a heading and a brief paragraph explaining what the feature does + with an example. + ## Acceptance and merging The kind of review and acceptance any merge proposal gets depends on diff --git a/docs/markdown/snippets/feature_new.md b/docs/markdown/snippets/feature_new.md index 7480634..94fb880 100644 --- a/docs/markdown/snippets/feature_new.md +++ b/docs/markdown/snippets/feature_new.md @@ -24,9 +24,9 @@ Project name: featurenew Project version: undefined Build machine cpu family: x86_64 Build machine cpu: x86_64 -WARNING: Project targetting '>=0.43' but tried to use feature introduced in '0.44.0': get_unquoted +WARNING: Project targetting '>=0.43' but tried to use feature introduced in '0.44.0': configuration_data.get_unquoted() Message: bar Build targets in project: 0 -Minimum version of features used: -0.44.0: {'get_unquoted'} +WARNING: Project specifies a minimum meson_version '>=0.43' which conflicts with: + * 0.44.0: {'configuration_data.get_unquoted()'} ``` diff --git a/mesonbuild/interpreter.py b/mesonbuild/interpreter.py index e39abd8..06d80ab 100644 --- a/mesonbuild/interpreter.py +++ b/mesonbuild/interpreter.py @@ -329,7 +329,7 @@ This will become a hard error in the future''') return args[1] raise InterpreterException('Entry %s not in configuration data.' % name) - @FeatureNew('configuration_data.get_unquoted', '0.44.0') + @FeatureNew('configuration_data.get_unquoted()', '0.44.0') def get_unquoted_method(self, args, kwargs): if len(args) < 1 or len(args) > 2: raise InterpreterException('Get method takes one or two arguments.') |