Converted macro to derive macro

This commit is contained in:
2025-08-30 04:20:27 +02:00
parent d2b01123b8
commit 5d342afb1f
17 changed files with 108 additions and 97 deletions

View File

@@ -2,7 +2,7 @@ use std::net::SocketAddr;
use anyhow::Result;
use async_trait::async_trait;
use automation_macro::{LuaDeviceConfig, impl_device};
use automation_macro::{LuaDevice, LuaDeviceConfig};
use google_home::errors::ErrorCode;
use google_home::traits::OnOff;
use tracing::{error, trace, warn};
@@ -19,11 +19,11 @@ pub struct Config {
pub scene_id: String,
}
#[derive(Debug, Clone)]
#[derive(Debug, Clone, LuaDevice)]
#[traits(OnOff)]
pub struct HueGroup {
config: Config,
}
impl_device!(HueGroup);
// Couple of helper function to get the correct urls
#[async_trait]