feat(configurations)!: flatten down, introduce meta.nix
Flatten down directory structure: - From: `./hosts/${configuration-type}/${system}/{configuration,deploy}.nix` - To: `./hosts/${configuration-type}/{meta,configuration}.nix` Keep `system` and `deploy-rs` config in `meta.nix` Update `flake.lock`
This commit is contained in:
parent
29738555b1
commit
9b8f894a1a
43 changed files with 459 additions and 344 deletions
27
hosts/nixos/jeeves/home-assistant/jokes.nix
Normal file
27
hosts/nixos/jeeves/home-assistant/jokes.nix
Normal file
|
@ -0,0 +1,27 @@
|
|||
{
|
||||
services.home-assistant.config = {
|
||||
conversation.intents = {
|
||||
TellJoke = [
|
||||
"Tell [me] (a joke|something funny|a dad joke)"
|
||||
];
|
||||
};
|
||||
sensor = [
|
||||
{
|
||||
name = "random_joke";
|
||||
platform = "rest";
|
||||
json_attributes = "joke";
|
||||
resource = "https://icanhazdadjoke.com/";
|
||||
scan_interval = "3600";
|
||||
headers.Accept = "application/json";
|
||||
}
|
||||
];
|
||||
|
||||
intent_script.TellJoke = {
|
||||
speech.text = ''{{ state_attr("sensor.random_joke", "joke") }}'';
|
||||
action = {
|
||||
service = "homeassistant.update_entity";
|
||||
entity_id = "sensor.random_joke";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue