diff options
author | Klaus Aehlig <klaus.aehlig@huawei.com> | 2024-10-21 17:14:35 +0200 |
---|---|---|
committer | Klaus Aehlig <klaus.aehlig@huawei.com> | 2024-10-21 17:14:35 +0200 |
commit | 81713238e6ffb59e8af6c42e2fc2510d4698ce71 (patch) | |
tree | e91fb1b06254a37c6c7e3968455469f1cb37a379 | |
parent | 01ae2737c6ea663ad4e741f048889950bbfb2510 (diff) | |
download | justbuild-81713238e6ffb59e8af6c42e2fc2510d4698ce71.tar.gz |
shell defaults: properly deduplicate "bin dirs" to the left
-rw-r--r-- | rules/shell/RULES | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/rules/shell/RULES b/rules/shell/RULES index 2ce078ef..5ac07e68 100644 --- a/rules/shell/RULES +++ b/rules/shell/RULES @@ -137,14 +137,24 @@ } ] , [ "bin dirs" - , { "type": "++" + , { "type": "reverse" , "$1": - [ {"type": "FIELD", "name": "bin dirs"} - , { "type": "let*" - , "bindings": [["provider", "bin dirs"]] - , "body": {"type": "CALL_EXPRESSION", "name": "base-provides-++"} + { "type": "nub_right" + , "$1": + { "type": "reverse" + , "$1": + { "type": "++" + , "$1": + [ {"type": "FIELD", "name": "bin dirs"} + , { "type": "let*" + , "bindings": [["provider", "bin dirs"]] + , "body": + {"type": "CALL_EXPRESSION", "name": "base-provides-++"} + } + ] + } } - ] + } } ] ] |