output.go
changeset 45 ea6a9ba7a3c8
parent 42 3fa13770e970
equal deleted inserted replaced
44:af90d9396ef1 45:ea6a9ba7a3c8
     1 /*
     1 /*
     2  * Copyright (C) 2014-2018 Mikael Berthe <mikael@lilotux.net>
     2  * Copyright (C) 2014-2022 Mikael Berthe <mikael@lilotux.net>
     3  *
     3  *
     4  * This program is free software; you can redistribute it and/or modify
     4  * This program is free software; you can redistribute it and/or modify
     5  * it under the terms of the GNU General Public License as published by
     5  * it under the terms of the GNU General Public License as published by
     6  * the Free Software Foundation; either version 2 of the License, or (at
     6  * the Free Software Foundation; either version 2 of the License, or (at
     7  * your option) any later version.
     7  * your option) any later version.
    63 		for i, g := range results.Groups {
    63 		for i, g := range results.Groups {
    64 			fmt.Printf("\nGroup #%d (%d files * %v):\n", i+1,
    64 			fmt.Printf("\nGroup #%d (%d files * %v):\n", i+1,
    65 				len(g.Paths), formatSize(g.FileSize, true))
    65 				len(g.Paths), formatSize(g.FileSize, true))
    66 			for _, f := range g.Paths {
    66 			for _, f := range g.Paths {
    67 				fmt.Println(f)
    67 				fmt.Println(f)
       
    68 				if g.Links != nil { // Display linked files
       
    69 					for _, lf := range g.Links[f] {
       
    70 						fmt.Printf(" %s\n", lf)
       
    71 					}
       
    72 				}
    68 			}
    73 			}
    69 		}
    74 		}
    70 	}
    75 	}
    71 
    76 
    72 	// We're done if we do not display statistics
    77 	// We're done if we do not display statistics