Add some missed imports in last commit.
This commit is contained in:
parent
89eae6f590
commit
dcf2994905
2 changed files with 2 additions and 18 deletions
|
@ -9,6 +9,7 @@ import (
|
|||
"github.com/conformal/btcdb"
|
||||
_ "github.com/conformal/btcdb/ldb"
|
||||
_ "github.com/conformal/btcdb/sqlite3"
|
||||
"github.com/conformal/btcutil"
|
||||
"github.com/conformal/btcwire"
|
||||
"github.com/conformal/go-flags"
|
||||
"os"
|
||||
|
|
|
@ -11,6 +11,7 @@ import (
|
|||
"github.com/conformal/btcdb"
|
||||
_ "github.com/conformal/btcdb/ldb"
|
||||
_ "github.com/conformal/btcdb/sqlite3"
|
||||
"github.com/conformal/btcutil"
|
||||
"github.com/conformal/btcwire"
|
||||
"github.com/conformal/go-flags"
|
||||
"github.com/conformal/seelog"
|
||||
|
@ -274,21 +275,3 @@ func parsesha(argstr string) (argtype int, height int64, psha *btcwire.ShaHash,
|
|||
psha = &sha
|
||||
return
|
||||
}
|
||||
|
||||
// btcdHomeDir returns an OS appropriate home directory for btcd.
|
||||
func btcdHomeDir() string {
|
||||
// Search for Windows APPDATA first. This won't exist on POSIX OSes.
|
||||
appData := os.Getenv("APPDATA")
|
||||
if appData != "" {
|
||||
return filepath.Join(appData, "btcd")
|
||||
}
|
||||
|
||||
// Fall back to standard HOME directory that works for most POSIX OSes.
|
||||
home := os.Getenv("HOME")
|
||||
if home != "" {
|
||||
return filepath.Join(home, ".btcd")
|
||||
}
|
||||
|
||||
// In the worst case, use the current directory.
|
||||
return "."
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue