mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-25 06:06:44 +00:00
cmd/geth: fix era1 download location to match store
This changes the era1 downloader to place the files into the correct location where geth will actually use them. Also adds integration with the new --datadir.era flag.
This commit is contained in:
parent
a7d9b52eaf
commit
820316f8a4
1 changed files with 5 additions and 1 deletions
|
|
@ -723,8 +723,12 @@ func downloadEra(ctx *cli.Context) error {
|
|||
// Resolve the destination directory.
|
||||
stack, _ := makeConfigNode(ctx)
|
||||
defer stack.Close()
|
||||
ancients := stack.ResolveAncient("chaindata", "")
|
||||
|
||||
ancients := stack.ResolveAncient("chaindata", "chain")
|
||||
dir := filepath.Join(ancients, "era")
|
||||
if ctx.IsSet(utils.EraFlag.Name) {
|
||||
dir = filepath.Join(ancients, ctx.String(utils.EraFlag.Name))
|
||||
}
|
||||
|
||||
baseURL := ctx.String(eraServerFlag.Name)
|
||||
if baseURL == "" {
|
||||
|
|
|
|||
Loading…
Reference in a new issue