Crate powernotd

Source

Modules§

config
notification

Enums§

ChargingStatus

Constants§

DEFAULT_BATTERY

Functions§

check_notify_full_battery
notify if battery is fully charged
find_lowest_threshold
Find lowest threshold which has been passed with the current battery level
get_charging_status_path
get_current_power
Return the current battery level
get_power_status_path
get_status_charging
notify_now
reset_other_notifications
Reset all notifications which are not the current threshold_val
run_command
send_message
send a message using linux notify-send api
send_notification
Send a notification using the rust_notify library. The title and message are used from the Notification if given and templated by replacing ‘{}’ with the current percentage. In addition, a system command is run if specified in the Notification.

Type Aliases§

Battery