Attribute Macro bitbar_derive::main
source · [−]#[main]Expand description
Annotate your main function with this.
- It can optionally take an argument of type
bitbar::Flavor. - It must return a member of the
bitbar::MainOutputtrait. - It can be a
fnor anasync fn. In the latter case,tokio’s threaded runtime will be used. (This requires thetokiofeature, which is on by default, or either of thetokio02ortokio03features, which are not.)
The main attribute optionally takes a parameter error_template_image which can be set to a path (relative to the current file) to a PNG file which will be used as the template image for the menu when displaying an error.