//! Bakes `icons/icon.ico` into the exe as its resource, so Explorer, shortcuts and the //! installer show the medallion the window and the tray also draw. fn main() { if std::env::var("CARGO_CFG_TARGET_OS").as_deref() != Ok("windows") { return; } let mut resource = winresource::WindowsResource::new(); resource.set_icon("icons/icon.ico"); resource.compile().expect("the icon resource compiles"); }