cachestats: deprecate in favour of rclone backend stats cache:

This commit is contained in:
Nick Craig-Wood 2020-04-29 10:09:17 +01:00
parent 90d738b561
commit cbc5af329f

View File

@ -9,6 +9,7 @@ import (
"github.com/pkg/errors"
"github.com/rclone/rclone/backend/cache"
"github.com/rclone/rclone/cmd"
"github.com/rclone/rclone/fs"
"github.com/spf13/cobra"
)
@ -22,8 +23,10 @@ var commandDefinition = &cobra.Command{
Long: `
Print cache stats for a remote in JSON format
`,
Hidden: true,
Run: func(command *cobra.Command, args []string) {
cmd.CheckArgs(1, 1, command, args)
fs.Logf(nil, `"rclone cachestats" is deprecated, use "rclone backend stats %s" instead`, args[0])
fsrc := cmd.NewFsSrc(args)
cmd.Run(false, false, command, func() error {