Ask for IoT class during scaffold (#49647)

Co-authored-by: Milan Meulemans <milan.meulemans@live.be>
Co-authored-by: Franck Nijhof <git@frenck.dev>
This commit is contained in:
Paulus Schoutsen
2021-04-25 03:13:22 -07:00
committed by GitHub
parent b92f29997e
commit 9f8e683ae3
5 changed files with 23 additions and 4 deletions

View File

@ -67,10 +67,10 @@ def _append(path: Path, text):
path.write_text(path.read_text() + text)
def _custom_tasks(template, info) -> None:
def _custom_tasks(template, info: Info) -> None:
"""Handle custom tasks for templates."""
if template == "integration":
changes = {"codeowners": [info.codeowner]}
changes = {"codeowners": [info.codeowner], "iot_class": info.iot_class}
if info.requirement:
changes["requirements"] = [info.requirement]