From 0391c57a375b6221a0628ec879a25fa5a6c7662a Mon Sep 17 00:00:00 2001 From: Simon Frei Date: Thu, 22 Nov 2018 11:39:01 +0100 Subject: [PATCH] cmd/syncthing: Improve logged device information on startup (#5321) --- cmd/syncthing/main.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/cmd/syncthing/main.go b/cmd/syncthing/main.go index ca33da4f..870f7b17 100644 --- a/cmd/syncthing/main.go +++ b/cmd/syncthing/main.go @@ -828,9 +828,11 @@ func syncthingMain(runtimeOptions RuntimeOptions) { pprof.StartCPUProfile(f) } + myDev, _ := cfg.Device(myID) + l.Infof(`My name is "%v"`, myDev.Name) for _, device := range cfg.Devices() { - if len(device.Name) > 0 { - l.Infof("Device %s is %q at %v", device.DeviceID, device.Name, device.Addresses) + if device.DeviceID != myID { + l.Infof(`Device %s is "%v" at %v`, device.DeviceID, device.Name, device.Addresses) } }