Browse Source

lint

pull/7450/head
chrislu 2 months ago
parent
commit
608c663d6e
  1. 2
      weed/shell/command_collection_delete.go
  2. 2
      weed/shell/command_ec_balance.go
  3. 2
      weed/shell/command_ec_rebuild.go
  4. 2
      weed/shell/command_fs_meta_change_volume_id.go
  5. 2
      weed/shell/command_volume_balance.go
  6. 2
      weed/shell/command_volume_check_disk.go
  7. 3
      weed/shell/command_volume_delete_empty.go
  8. 2
      weed/shell/command_volume_fix_replication.go
  9. 2
      weed/shell/command_volume_server_evacuate.go
  10. 2
      weed/shell/command_volume_tier_move.go

2
weed/shell/command_collection_delete.go

@ -50,7 +50,7 @@ func (c *commandCollectionDelete) Do(args []string, commandEnv *CommandEnv, writ
}
if *applyBalancingAlias != false {
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead")
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead\n")
*applyBalancing = *applyBalancingAlias
}
if *collectionName == "" {

2
weed/shell/command_ec_balance.go

@ -50,7 +50,7 @@ func (c *commandEcBalance) Do(args []string, commandEnv *CommandEnv, writer io.W
}
if *applyBalancingAlias != false {
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead")
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead\n")
*applyBalancing = *applyBalancingAlias
}

2
weed/shell/command_ec_rebuild.go

@ -76,7 +76,7 @@ func (c *commandEcRebuild) Do(args []string, commandEnv *CommandEnv, writer io.W
}
if *applyChangesAlias != false {
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead")
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead\n")
*applyChanges = *applyChangesAlias
}

2
weed/shell/command_fs_meta_change_volume_id.go

@ -58,7 +58,7 @@ func (c *commandFsMetaChangeVolumeId) Do(args []string, commandEnv *CommandEnv,
}
if *applyChangesAlias != false {
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead")
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead\n")
*applyChanges = *applyChangesAlias
}

2
weed/shell/command_volume_balance.go

@ -99,7 +99,7 @@ func (c *commandVolumeBalance) Do(args []string, commandEnv *CommandEnv, writer
return nil
}
if *applyBalancingAlias != false {
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead")
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead\n")
*applyBalancing = *applyBalancingAlias
}
c.writable = *writable

2
weed/shell/command_volume_check_disk.go

@ -135,7 +135,7 @@ func (c *commandVolumeCheckDisk) Do(args []string, commandEnv *CommandEnv, write
}
if *applyChangesAlias != false {
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead")
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead\n")
*applyChanges = *applyChangesAlias
}
c.env = commandEnv

3
weed/shell/command_volume_delete_empty.go

@ -2,6 +2,7 @@ package shell
import (
"flag"
"fmt"
"io"
"log"
"time"
@ -53,7 +54,7 @@ func (c *commandVolumeDeleteEmpty) Do(args []string, commandEnv *CommandEnv, wri
return
}
if *applyBalancingAlias != false {
log.Printf("WARNING: -force is deprecated, please use -apply instead")
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead\n")
*applyBalancing = *applyBalancingAlias
}

2
weed/shell/command_volume_fix_replication.go

@ -81,7 +81,7 @@ func (c *commandVolumeFixReplication) Do(args []string, commandEnv *CommandEnv,
infoAboutSimulationMode(writer, *applyChanges, "-apply")
if *applyChangesAlias != false {
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead")
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead\n")
*applyChanges = *applyChangesAlias
}
commandEnv.noLock = !*applyChanges

2
weed/shell/command_volume_server_evacuate.go

@ -72,7 +72,7 @@ func (c *commandVolumeServerEvacuate) Do(args []string, commandEnv *CommandEnv,
}
if *applyChangeAlias != false {
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead")
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead\n")
*applyChange = *applyChangeAlias
}
if *volumeServer == "" && *c.volumeRack == "" {

2
weed/shell/command_volume_tier_move.go

@ -82,7 +82,7 @@ func (c *commandVolumeTierMove) Do(args []string, commandEnv *CommandEnv, writer
}
if *applyChangeAlias != false {
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead")
fmt.Fprintf(writer, "WARNING: -force is deprecated, please use -apply instead\n")
*applyChange = *applyChangeAlias
}
fromDiskType := types.ToDiskType(*source)

Loading…
Cancel
Save