Skip to content

Commit

Permalink
chore: lint unrelated file
Browse files Browse the repository at this point in the history
this file was edited in Alexays#2558 but not linted
  • Loading branch information
Syndelis committed Oct 9, 2023
1 parent 592d564 commit f8340d8
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/modules/disk.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ auto waybar::modules::Disk::update() -> void {
float specific_free, specific_used, specific_total, divisor;

divisor = calc_specific_divisor(unit_);
specific_free = (stats.f_bavail * stats.f_frsize)/divisor;
specific_used = ((stats.f_blocks - stats.f_bfree) * stats.f_frsize)/divisor;
specific_total = (stats.f_blocks * stats.f_frsize)/divisor;
specific_free = (stats.f_bavail * stats.f_frsize) / divisor;
specific_used = ((stats.f_blocks - stats.f_bfree) * stats.f_frsize) / divisor;
specific_total = (stats.f_blocks * stats.f_frsize) / divisor;

auto free = pow_format(stats.f_bavail * stats.f_frsize, "B", true);
auto used = pow_format((stats.f_blocks - stats.f_bfree) * stats.f_frsize, "B", true);
Expand All @@ -72,7 +72,7 @@ auto waybar::modules::Disk::update() -> void {
fmt::runtime(format), stats.f_bavail * 100 / stats.f_blocks, fmt::arg("free", free),
fmt::arg("percentage_free", stats.f_bavail * 100 / stats.f_blocks), fmt::arg("used", used),
fmt::arg("percentage_used", percentage_used), fmt::arg("total", total),
fmt::arg("path", path_), fmt::arg("specific_free", specific_free),
fmt::arg("path", path_), fmt::arg("specific_free", specific_free),
fmt::arg("specific_used", specific_used), fmt::arg("specific_total", specific_total)));
}

Expand All @@ -85,7 +85,7 @@ auto waybar::modules::Disk::update() -> void {
fmt::runtime(tooltip_format), stats.f_bavail * 100 / stats.f_blocks, fmt::arg("free", free),
fmt::arg("percentage_free", stats.f_bavail * 100 / stats.f_blocks), fmt::arg("used", used),
fmt::arg("percentage_used", percentage_used), fmt::arg("total", total),
fmt::arg("path", path_), fmt::arg("specific_free", specific_free),
fmt::arg("path", path_), fmt::arg("specific_free", specific_free),
fmt::arg("specific_used", specific_used), fmt::arg("specific_total", specific_total)));
}
// Call parent update
Expand All @@ -109,7 +109,7 @@ float waybar::modules::Disk::calc_specific_divisor(std::string divisor) {
return 1000.0 * 1000.0 * 1000.0 * 1000.0;
} else if (divisor == "TiB") {
return 1024.0 * 1024.0 * 1024.0 * 1024.0;
} else { //default to Bytes if it is anything that we don't recongnise
} else { // default to Bytes if it is anything that we don't recongnise
return 1.0;
}
}

0 comments on commit f8340d8

Please sign in to comment.