cmd/bzzd: make no swap default, renamed flag bzznoswap->bzzswap

This commit is contained in:
zelig 2016-11-28 09:07:43 +01:00
parent 36f5e2a6fc
commit fc3736f237

View file

@ -66,9 +66,9 @@ var (
Name: "bzzconfig", Name: "bzzconfig",
Usage: "Swarm config file path (datadir/bzz)", Usage: "Swarm config file path (datadir/bzz)",
} }
SwarmSwapDisabled = cli.BoolFlag{ SwarmSwapEnabled = cli.BoolFlag{
Name: "bzznoswap", Name: "bzzswap",
Usage: "Swarm SWAP disabled (default false)", Usage: "Swarm SWAP enabled (default false)",
} }
SwarmSyncDisabled = cli.BoolFlag{ SwarmSyncDisabled = cli.BoolFlag{
Name: "bzznosync", Name: "bzznosync",
@ -110,7 +110,7 @@ func init() {
// bzzd-specific flags // bzzd-specific flags
EthAPI, EthAPI,
SwarmConfigPathFlag, SwarmConfigPathFlag,
SwarmSwapDisabled, SwarmSwapEnabled,
SwarmSyncDisabled, SwarmSyncDisabled,
SwarmPortFlag, SwarmPortFlag,
SwarmAccountFlag, SwarmAccountFlag,
@ -167,7 +167,7 @@ func registerBzzService(ctx *cli.Context, stack *node.Node) {
if len(bzzport) > 0 { if len(bzzport) > 0 {
bzzconfig.Port = bzzport bzzconfig.Port = bzzport
} }
swapEnabled := !ctx.GlobalBool(SwarmSwapDisabled.Name) swapEnabled := ctx.GlobalBool(SwarmSwapEnabled.Name)
syncEnabled := !ctx.GlobalBool(SwarmSyncDisabled.Name) syncEnabled := !ctx.GlobalBool(SwarmSyncDisabled.Name)
ethapi := ctx.GlobalString(EthAPI.Name) ethapi := ctx.GlobalString(EthAPI.Name)