mirror of
https://github.com/esphome/esphome.git
synced 2025-08-05 09:57:47 +00:00
Merge remote-tracking branch 'upstream/dev' into integration
This commit is contained in:
commit
ec3660e8ae
30
.github/workflows/ci.yml
vendored
30
.github/workflows/ci.yml
vendored
@ -345,20 +345,31 @@ jobs:
|
|||||||
run: script/ci-suggest-changes
|
run: script/ci-suggest-changes
|
||||||
if: always()
|
if: always()
|
||||||
|
|
||||||
|
clang-tidy-deps:
|
||||||
|
name: Clang-tidy dependencies
|
||||||
|
runs-on: ubuntu-24.04
|
||||||
|
needs:
|
||||||
|
- common
|
||||||
|
- ci-custom
|
||||||
|
- clang-format
|
||||||
|
- pytest
|
||||||
|
- determine-jobs
|
||||||
|
if: |
|
||||||
|
always() &&
|
||||||
|
needs.determine-jobs.outputs.clang-tidy == 'true'
|
||||||
|
steps:
|
||||||
|
- run: echo "All clang-tidy dependencies ready"
|
||||||
|
|
||||||
clang-tidy:
|
clang-tidy:
|
||||||
name: ${{ matrix.name }}
|
name: ${{ matrix.name }}
|
||||||
runs-on: ubuntu-24.04
|
runs-on: ubuntu-24.04
|
||||||
needs:
|
needs:
|
||||||
- common
|
- clang-tidy-deps
|
||||||
- ruff
|
|
||||||
- ci-custom
|
|
||||||
- clang-format
|
|
||||||
- flake8
|
|
||||||
- pylint
|
|
||||||
- pytest
|
|
||||||
- pyupgrade
|
|
||||||
- determine-jobs
|
- determine-jobs
|
||||||
if: needs.determine-jobs.outputs.clang-tidy == 'true'
|
if: |
|
||||||
|
always() &&
|
||||||
|
needs.determine-jobs.outputs.clang-tidy == 'true' &&
|
||||||
|
needs.clang-tidy-deps.result == 'success'
|
||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ github.token }}
|
GH_TOKEN: ${{ github.token }}
|
||||||
strategy:
|
strategy:
|
||||||
@ -575,6 +586,7 @@ jobs:
|
|||||||
- pytest
|
- pytest
|
||||||
- integration-tests
|
- integration-tests
|
||||||
- pyupgrade
|
- pyupgrade
|
||||||
|
- clang-tidy-deps
|
||||||
- clang-tidy
|
- clang-tidy
|
||||||
- determine-jobs
|
- determine-jobs
|
||||||
- test-build-components
|
- test-build-components
|
||||||
|
@ -1,6 +1,13 @@
|
|||||||
---
|
---
|
||||||
# See https://pre-commit.com for more information
|
# See https://pre-commit.com for more information
|
||||||
# See https://pre-commit.com/hooks.html for more hooks
|
# See https://pre-commit.com/hooks.html for more hooks
|
||||||
|
|
||||||
|
ci:
|
||||||
|
autoupdate_commit_msg: 'pre-commit: autoupdate'
|
||||||
|
autoupdate_schedule: weekly
|
||||||
|
# Skip hooks that have issues in pre-commit CI environment
|
||||||
|
skip: [pylint, clang-tidy-hash, yamllint]
|
||||||
|
|
||||||
repos:
|
repos:
|
||||||
- repo: https://github.com/astral-sh/ruff-pre-commit
|
- repo: https://github.com/astral-sh/ruff-pre-commit
|
||||||
# Ruff version.
|
# Ruff version.
|
||||||
|
@ -146,8 +146,11 @@ def _substitute_item(substitutions, item, path, jinja, ignore_missing):
|
|||||||
if sub is not None:
|
if sub is not None:
|
||||||
item[k] = sub
|
item[k] = sub
|
||||||
for old, new in replace_keys:
|
for old, new in replace_keys:
|
||||||
item[new] = merge_config(item.get(old), item.get(new))
|
if str(new) == str(old):
|
||||||
del item[old]
|
item[new] = item[old]
|
||||||
|
else:
|
||||||
|
item[new] = merge_config(item.get(old), item.get(new))
|
||||||
|
del item[old]
|
||||||
elif isinstance(item, str):
|
elif isinstance(item, str):
|
||||||
sub = _expand_substitutions(substitutions, item, path, jinja, ignore_missing)
|
sub = _expand_substitutions(substitutions, item, path, jinja, ignore_missing)
|
||||||
if isinstance(sub, JinjaStr) or sub != item:
|
if isinstance(sub, JinjaStr) or sub != item:
|
||||||
|
@ -17,3 +17,5 @@ test_list:
|
|||||||
- ${undefined_var}
|
- ${undefined_var}
|
||||||
- $undefined_var
|
- $undefined_var
|
||||||
- ${ undefined_var }
|
- ${ undefined_var }
|
||||||
|
- key1: 1
|
||||||
|
key2: 2
|
||||||
|
@ -19,3 +19,5 @@ test_list:
|
|||||||
- ${undefined_var}
|
- ${undefined_var}
|
||||||
- $undefined_var
|
- $undefined_var
|
||||||
- ${ undefined_var }
|
- ${ undefined_var }
|
||||||
|
- key${var1}: 1
|
||||||
|
key${var2}: 2
|
||||||
|
@ -6,6 +6,7 @@ package_result:
|
|||||||
root file
|
root file
|
||||||
- Double substitution also works; the value of var7 is 79, where A is a package
|
- Double substitution also works; the value of var7 is 79, where A is a package
|
||||||
var
|
var
|
||||||
|
- key79: Key should substitute to key79
|
||||||
local_results:
|
local_results:
|
||||||
- The value of B is 5
|
- The value of B is 5
|
||||||
- 'You will see, however, that
|
- 'You will see, however, that
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
package_result:
|
package_result:
|
||||||
- The value of A*B is ${A * B}, where A is a package var and B is a substitution in the root file
|
- The value of A*B is ${A * B}, where A is a package var and B is a substitution in the root file
|
||||||
- Double substitution also works; the value of var7 is ${var$A}, where A is a package var
|
- Double substitution also works; the value of var7 is ${var$A}, where A is a package var
|
||||||
|
- key${var7}: Key should substitute to key79
|
||||||
|
Loading…
x
Reference in New Issue
Block a user