Skip to content

Commit

Permalink
Comment out logging statements
Browse files Browse the repository at this point in the history
  • Loading branch information
ycombinator committed Aug 29, 2023
1 parent ad9ffc9 commit 1ce2505
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions copy.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package copy

import (
"fmt"
"io"
"io/fs"
"io/ioutil"
Expand Down Expand Up @@ -228,30 +227,30 @@ func hasAllSSDs() bool {

block, err := ghw.Block()
if err != nil {
fmt.Fprintf(os.Stderr, "ghw.Block() returned error: %s\n", err.Error())
//fmt.Fprintf(os.Stderr, "ghw.Block() returned error: %s\n", err.Error())
_hasAllSSDs.Store(false)
return false
}

for _, disk := range block.Disks {
fmt.Fprintf(os.Stderr, "Disk %s is a ", disk.Name)
//fmt.Fprintf(os.Stderr, "Disk %s is a ", disk.Name)
switch disk.DriveType {
case ghw.DRIVE_TYPE_FDD, ghw.DRIVE_TYPE_ODD:
// Floppy or optical drive; we don't care about these
fmt.Fprintln(os.Stderr, "FDD or ODD")
//fmt.Fprintln(os.Stderr, "FDD or ODD")
continue
case ghw.DRIVE_TYPE_SSD:
// SSDs
fmt.Fprintln(os.Stderr, "SSD")
//fmt.Fprintln(os.Stderr, "SSD")
continue
default:
fmt.Fprintln(os.Stderr, "HDD or unknown")
//fmt.Fprintln(os.Stderr, "HDD or unknown")
_hasAllSSDs.Store(false)
return false
}
}

fmt.Fprintln(os.Stderr, "All SSDs detected")
//fmt.Fprintln(os.Stderr, "All SSDs detected")
_hasAllSSDs.Store(true)
return true
}
Expand Down

0 comments on commit 1ce2505

Please sign in to comment.