#[cfg(any(target_os = "macos", target_os = "linux"))]
mod common;
#[cfg(target_os = "macos")]
mod macos;
#[cfg(target_os = "linux")]
mod linux;
#[cfg(target_os = "macos")]
pub use macos::{install, uninstall};
#[cfg(target_os = "linux")]
pub use linux::{install, uninstall};
#[cfg(all(test, target_os = "linux"))]
use linux::{render_unit, unit_path};
#[cfg(all(test, target_os = "macos"))]
use macos::{
launchctl_bin, plist_path, plist_path_from_home, render_plist, write_plist, xml_escape,
};
#[cfg(not(any(target_os = "macos", target_os = "linux")))]
pub fn install() -> anyhow::Result<()> {
anyhow::bail!("`moadim install` is not supported on this platform yet")
}
#[cfg(not(any(target_os = "macos", target_os = "linux")))]
pub fn uninstall() -> anyhow::Result<()> {
anyhow::bail!("`moadim uninstall` is not supported on this platform yet")
}
#[cfg(test)]
#[path = "mod_tests.rs"]
mod service_tests;