mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-22 17:33:23 +01:00
Add dev config to login automagically based on dot file (#8598)
* Add dev config to login automagically based on runtime config Co-authored-by: Erik Marks <rekmarks@protonmail.com>
This commit is contained in:
parent
d488c16df5
commit
c413d0905f
2
.gitignore
vendored
2
.gitignore
vendored
@ -49,3 +49,5 @@ notes.txt
|
||||
|
||||
.coveralls.yml
|
||||
.nyc_output
|
||||
|
||||
.metamaskrc
|
||||
|
@ -338,6 +338,14 @@ export default class MetamaskController extends EventEmitter {
|
||||
EnsController: this.ensController.store,
|
||||
})
|
||||
this.memStore.subscribe(this.sendUpdate.bind(this))
|
||||
|
||||
const password = process.env.CONF?.password
|
||||
if (
|
||||
password && !this.isUnlocked() &&
|
||||
this.onboardingController.completedOnboarding
|
||||
) {
|
||||
this.submitPassword(password)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -15,6 +15,7 @@ const pify = require('pify')
|
||||
const endOfStream = pify(require('end-of-stream'))
|
||||
const { makeStringTransform } = require('browserify-transform-tools')
|
||||
|
||||
const conf = require('rc')('metamask', {})
|
||||
|
||||
const { createTask, composeParallel, composeSeries, runInChildProcess } = require('./task')
|
||||
const packageJSON = require('../../package.json')
|
||||
@ -337,6 +338,7 @@ function createScriptTasks ({ browserPlatforms, livereload }) {
|
||||
IN_TEST: opts.testing ? 'true' : false,
|
||||
PUBNUB_SUB_KEY: process.env.PUBNUB_SUB_KEY || '',
|
||||
PUBNUB_PUB_KEY: process.env.PUBNUB_PUB_KEY || '',
|
||||
CONF: opts.devMode ? conf : ({}),
|
||||
}), {
|
||||
global: true,
|
||||
})
|
||||
|
@ -264,6 +264,7 @@
|
||||
"qs": "^6.2.0",
|
||||
"qunitjs": "^2.4.1",
|
||||
"randomcolor": "^0.5.4",
|
||||
"rc": "^1.2.8",
|
||||
"react-devtools": "^4.4.0",
|
||||
"react-test-renderer": "^16.12.0",
|
||||
"read-installed": "^4.0.3",
|
||||
|
Loading…
Reference in New Issue
Block a user