From 51b645f8d07c5c6f01ca1c201c7f6a026d2f9fb3 Mon Sep 17 00:00:00 2001 From: Phi Date: Fri, 3 Mar 2023 14:13:35 +0100 Subject: [PATCH] Hide `lotus-worker set` command Hide the `lotus-worker set` command and print that this command will be deprecated. --- cmd/lotus-worker/cli.go | 6 ++++-- documentation/en/cli-lotus-worker.md | 14 -------------- 2 files changed, 4 insertions(+), 16 deletions(-) diff --git a/cmd/lotus-worker/cli.go b/cmd/lotus-worker/cli.go index d2a81688aa3..393ece18c86 100644 --- a/cmd/lotus-worker/cli.go +++ b/cmd/lotus-worker/cli.go @@ -10,8 +10,9 @@ import ( ) var setCmd = &cli.Command{ - Name: "set", - Usage: "Manage worker settings", + Name: "set", + Usage: "Manage worker settings", + Hidden: true, Flags: []cli.Flag{ &cli.BoolFlag{ Name: "enabled", @@ -20,6 +21,7 @@ var setCmd = &cli.Command{ }, }, Action: func(cctx *cli.Context) error { + fmt.Println("DEPRECATED: This command will be removed in the future") api, closer, err := lcli.GetWorkerAPI(cctx) if err != nil { return err diff --git a/documentation/en/cli-lotus-worker.md b/documentation/en/cli-lotus-worker.md index efa7ffd3fbb..7b52a1c4f3b 100644 --- a/documentation/en/cli-lotus-worker.md +++ b/documentation/en/cli-lotus-worker.md @@ -14,7 +14,6 @@ COMMANDS: stop Stop a running lotus worker info Print worker info storage manage sector storage - set Manage worker settings resources Manage resource table overrides tasks Manage task processing help, h Shows a list of commands or help for one command @@ -153,19 +152,6 @@ OPTIONS: ``` -## lotus-worker set -``` -NAME: - lotus-worker set - Manage worker settings - -USAGE: - lotus-worker set [command options] [arguments...] - -OPTIONS: - --enabled enable/disable new task processing (default: true) - -``` - ## lotus-worker resources ``` NAME: