mirror of
https://github.com/bootandy/dust.git
synced 2026-06-08 11:29:05 +03:00
Remove commented out code
This commit is contained in:
@@ -282,13 +282,6 @@ fn find_big_ones<'a>(l: &'a Vec<Node>, max_to_show: usize) -> Vec<&Node> {
|
|||||||
.collect();
|
.collect();
|
||||||
new_l.extend(b_list);
|
new_l.extend(b_list);
|
||||||
new_l.sort();
|
new_l.sort();
|
||||||
/*println!(
|
|
||||||
"{:?} -------------------",
|
|
||||||
new_l
|
|
||||||
.iter()
|
|
||||||
.map(|a| a.dir.size.to_string() + ": " + &a.dir.name)
|
|
||||||
.collect::<Vec<String>>()
|
|
||||||
);*/
|
|
||||||
}
|
}
|
||||||
if new_l.len() > max_to_show {
|
if new_l.len() > max_to_show {
|
||||||
new_l[0..max_to_show + 1].to_vec()
|
new_l[0..max_to_show + 1].to_vec()
|
||||||
@@ -390,8 +383,6 @@ fn print_this_node(node_to_print: &Node, is_biggest: bool, depth: u8, indentatio
|
|||||||
fn human_readable_number(size: u64) -> (String) {
|
fn human_readable_number(size: u64) -> (String) {
|
||||||
let units = vec!["T", "G", "M", "K"]; //make static
|
let units = vec!["T", "G", "M", "K"]; //make static
|
||||||
|
|
||||||
//return format!("{}B", size);
|
|
||||||
|
|
||||||
for (i, u) in units.iter().enumerate() {
|
for (i, u) in units.iter().enumerate() {
|
||||||
let marker = 1024u64.pow((units.len() - i) as u32);
|
let marker = 1024u64.pow((units.len() - i) as u32);
|
||||||
if size >= marker {
|
if size >= marker {
|
||||||
|
|||||||
Reference in New Issue
Block a user