mirror of
https://github.com/balena-io/balena-cli.git
synced 2025-01-18 10:46:34 +00:00
Remove fetching of Mixpanel token
Change-type: patch Signed-off-by: Paulo Castro <paulo@balena.io>
This commit is contained in:
parent
9ef99a3aa9
commit
6124d8c493
@ -9,12 +9,14 @@ import packageJSON = require('../package.json');
|
|||||||
|
|
||||||
const getBalenaSdk = _.once(() => BalenaSdk.fromSharedOptions());
|
const getBalenaSdk = _.once(() => BalenaSdk.fromSharedOptions());
|
||||||
const getMatchCommandAsync = Promise.promisify(Capitano.state.getMatchCommand);
|
const getMatchCommandAsync = Promise.promisify(Capitano.state.getMatchCommand);
|
||||||
const getMixpanel = _.once<any>(() =>
|
const getMixpanel = _.once<any>(() => {
|
||||||
getBalenaSdk()
|
const settings = require('balena-settings-client');
|
||||||
.models.config.getAll()
|
return Mixpanel.init('00000000000000000000000000000000', {
|
||||||
.get('mixpanelToken')
|
host: `api.${settings.get('balenaUrl')}`,
|
||||||
.then(Mixpanel.init),
|
path: '/mixpanel',
|
||||||
);
|
protocol: 'https',
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
export function trackCommand(capitanoCli: Capitano.Cli) {
|
export function trackCommand(capitanoCli: Capitano.Cli) {
|
||||||
const balena = getBalenaSdk();
|
const balena = getBalenaSdk();
|
||||||
|
@ -96,6 +96,7 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@resin.io/valid-email": "^0.1.0",
|
"@resin.io/valid-email": "^0.1.0",
|
||||||
"@types/dockerode": "2.5.5",
|
"@types/dockerode": "2.5.5",
|
||||||
|
"@types/mixpanel": "2.14.0",
|
||||||
"@types/stream-to-promise": "2.2.0",
|
"@types/stream-to-promise": "2.2.0",
|
||||||
"@types/through2": "^2.0.33",
|
"@types/through2": "^2.0.33",
|
||||||
"@zeit/dockerignore": "0.0.3",
|
"@zeit/dockerignore": "0.0.3",
|
||||||
@ -141,7 +142,7 @@
|
|||||||
"klaw": "^3.0.0",
|
"klaw": "^3.0.0",
|
||||||
"lodash": "^4.17.4",
|
"lodash": "^4.17.4",
|
||||||
"minimatch": "^3.0.4",
|
"minimatch": "^3.0.4",
|
||||||
"mixpanel": "^0.4.0",
|
"mixpanel": "^0.10.1",
|
||||||
"mkdirp": "^0.5.1",
|
"mkdirp": "^0.5.1",
|
||||||
"moment": "^2.20.1",
|
"moment": "^2.20.1",
|
||||||
"moment-duration-format": "^2.2.1",
|
"moment-duration-format": "^2.2.1",
|
||||||
|
1
typings/mixpanel.d.ts
vendored
1
typings/mixpanel.d.ts
vendored
@ -1 +0,0 @@
|
|||||||
declare module 'mixpanel';
|
|
Loading…
Reference in New Issue
Block a user