Made the impl_device macro more explicit about the implemented traits
This also converts impl_device into a procedural macro and get rid of a lot of "magic" that was happening.
This commit is contained in:
@@ -2,7 +2,7 @@ use std::net::SocketAddr;
|
||||
|
||||
use anyhow::Result;
|
||||
use async_trait::async_trait;
|
||||
use automation_macro::LuaDeviceConfig;
|
||||
use automation_macro::{LuaDeviceConfig, impl_device};
|
||||
use google_home::errors::ErrorCode;
|
||||
use google_home::traits::OnOff;
|
||||
use tracing::{error, trace, warn};
|
||||
@@ -23,6 +23,7 @@ pub struct Config {
|
||||
pub struct HueGroup {
|
||||
config: Config,
|
||||
}
|
||||
impl_device!(HueGroup);
|
||||
|
||||
// Couple of helper function to get the correct urls
|
||||
#[async_trait]
|
||||
|
||||
Reference in New Issue
Block a user