mirror of
https://gitlab.com/pulsechaincom/erigon-pulse.git
synced 2024-12-27 22:28:21 +00:00
117838e213
* Move compatibility check * Implement Alex's suggestion * Use root context * Fix lint * Fix lint Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
24 lines
547 B
Go
24 lines
547 B
Go
package commands
|
|
|
|
import (
|
|
"github.com/ledgerwatch/turbo-geth/cmd/state/verify"
|
|
"github.com/ledgerwatch/turbo-geth/cmd/utils"
|
|
"github.com/spf13/cobra"
|
|
)
|
|
|
|
func init() {
|
|
withDatadir(checkIndexCMD)
|
|
withIndexBucket(checkIndexCMD)
|
|
withCSBucket(checkIndexCMD)
|
|
rootCmd.AddCommand(checkIndexCMD)
|
|
}
|
|
|
|
var checkIndexCMD = &cobra.Command{
|
|
Use: "checkIndex",
|
|
Short: "Index checker",
|
|
RunE: func(cmd *cobra.Command, args []string) error {
|
|
ctx, _ := utils.RootContext()
|
|
return verify.CheckIndex(ctx, chaindata, changeSetBucket, indexBucket)
|
|
},
|
|
}
|