fix: remove blockchain utils module
This commit is contained in:
parent
de832e435b
commit
fc4af4885a
7 changed files with 14 additions and 21 deletions
|
|
@ -8,7 +8,7 @@ const inquirer = require('inquirer')
|
|||
const _ = require('lodash/fp')
|
||||
|
||||
const { utils: coinUtils } = require('lamassu-coins')
|
||||
const blockchainUtils = require('../blockchain-utils')
|
||||
const options = require('../options')
|
||||
|
||||
const common = require('./common')
|
||||
const doVolume = require('./do-volume')
|
||||
|
|
@ -29,7 +29,7 @@ const PLUGINS = {
|
|||
module.exports = {run}
|
||||
|
||||
function installedVolumeFilePath (crypto) {
|
||||
return path.resolve(coinUtils.cryptoDir(crypto, blockchainUtils.blockchainDir()), '.installed')
|
||||
return path.resolve(coinUtils.cryptoDir(crypto, options.blockchainDir), '.installed')
|
||||
}
|
||||
|
||||
function isInstalledVolume (crypto) {
|
||||
|
|
@ -59,7 +59,7 @@ function processCryptos (codes) {
|
|||
_.forEach(setupCrypto, selectedCryptos)
|
||||
common.es('sudo service supervisor restart')
|
||||
|
||||
const blockchainDir = blockchainUtils.blockchainDir()
|
||||
const blockchainDir = options.blockchainDir
|
||||
const backupDir = path.resolve(os.homedir(), 'backups')
|
||||
const rsyncCmd = `( \
|
||||
(crontab -l 2>/dev/null || echo -n "") | grep -v "@daily rsync ".*"wallet.dat"; \
|
||||
|
|
@ -74,7 +74,7 @@ function processCryptos (codes) {
|
|||
|
||||
function setupCrypto (crypto) {
|
||||
logger.info(`Installing ${crypto.display}...`)
|
||||
const cryptoDir = coinUtils.cryptoDir(crypto, blockchainUtils.blockchainDir())
|
||||
const cryptoDir = coinUtils.cryptoDir(crypto, options.blockchainDir)
|
||||
makeDir.sync(cryptoDir)
|
||||
const cryptoPlugin = plugin(crypto)
|
||||
const oldDir = process.cwd()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue