@ledgerhq/live-cli 22.9.1 → 22.9.2-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cli.js +9 -10
- package/lib/cli.js.map +1 -1
- package/lib/commands/app.d.ts.map +1 -1
- package/lib/commands/app.js +20 -29
- package/lib/commands/app.js.map +1 -1
- package/lib/commands/appUninstallAll.d.ts +1 -1
- package/lib/commands/appUninstallAll.d.ts.map +1 -1
- package/lib/commands/appUninstallAll.js +17 -9
- package/lib/commands/appUninstallAll.js.map +1 -1
- package/lib/commands/appsCheckAllAppVersions.d.ts.map +1 -1
- package/lib/commands/appsCheckAllAppVersions.js +36 -49
- package/lib/commands/appsCheckAllAppVersions.js.map +1 -1
- package/lib/commands/appsInstallAll.js +5 -5
- package/lib/commands/appsInstallAll.js.map +1 -1
- package/lib/commands/appsUpdateTestAll.d.ts.map +1 -1
- package/lib/commands/appsUpdateTestAll.js +10 -15
- package/lib/commands/appsUpdateTestAll.js.map +1 -1
- package/lib/commands/balanceHistory.d.ts.map +1 -1
- package/lib/commands/balanceHistory.js +13 -15
- package/lib/commands/balanceHistory.js.map +1 -1
- package/lib/commands/bot.js +4 -4
- package/lib/commands/bot.js.map +1 -1
- package/lib/commands/botPortfolio.d.ts.map +1 -1
- package/lib/commands/botPortfolio.js +7 -9
- package/lib/commands/botPortfolio.js.map +1 -1
- package/lib/commands/botTransfer.d.ts.map +1 -1
- package/lib/commands/botTransfer.js +19 -20
- package/lib/commands/botTransfer.js.map +1 -1
- package/lib/commands/broadcast.d.ts.map +1 -1
- package/lib/commands/broadcast.js +4 -4
- package/lib/commands/broadcast.js.map +1 -1
- package/lib/commands/cleanSpeculos.js +3 -3
- package/lib/commands/cleanSpeculos.js.map +1 -1
- package/lib/commands/confirmOp.d.ts.map +1 -1
- package/lib/commands/confirmOp.js +7 -9
- package/lib/commands/confirmOp.js.map +1 -1
- package/lib/commands/countervalues.d.ts.map +1 -1
- package/lib/commands/countervalues.js +30 -33
- package/lib/commands/countervalues.js.map +1 -1
- package/lib/commands/derivation.js +6 -6
- package/lib/commands/derivation.js.map +1 -1
- package/lib/commands/devDeviceAppsScenario.d.ts.map +1 -1
- package/lib/commands/devDeviceAppsScenario.js +11 -33
- package/lib/commands/devDeviceAppsScenario.js.map +1 -1
- package/lib/commands/deviceAppVersion.js +4 -4
- package/lib/commands/deviceAppVersion.js.map +1 -1
- package/lib/commands/deviceInfo.js +4 -4
- package/lib/commands/deviceInfo.js.map +1 -1
- package/lib/commands/deviceSDKFirmwareUpdate.d.ts.map +1 -1
- package/lib/commands/deviceSDKFirmwareUpdate.js +50 -58
- package/lib/commands/deviceSDKFirmwareUpdate.js.map +1 -1
- package/lib/commands/deviceSDKGetDeviceInfo.js +4 -4
- package/lib/commands/deviceSDKGetDeviceInfo.js.map +1 -1
- package/lib/commands/deviceSDKToggleOnboardingEarlyCheck.d.ts +1 -1
- package/lib/commands/deviceSDKToggleOnboardingEarlyCheck.d.ts.map +1 -1
- package/lib/commands/deviceSDKToggleOnboardingEarlyCheck.js +7 -6
- package/lib/commands/deviceSDKToggleOnboardingEarlyCheck.js.map +1 -1
- package/lib/commands/deviceVersion.js +4 -4
- package/lib/commands/deviceVersion.js.map +1 -1
- package/lib/commands/discoverDevices.d.ts.map +1 -1
- package/lib/commands/discoverDevices.js +7 -13
- package/lib/commands/discoverDevices.js.map +1 -1
- package/lib/commands/envs.d.ts.map +1 -1
- package/lib/commands/envs.js +4 -6
- package/lib/commands/envs.js.map +1 -1
- package/lib/commands/estimateMaxSpendable.d.ts.map +1 -1
- package/lib/commands/estimateMaxSpendable.js +6 -6
- package/lib/commands/estimateMaxSpendable.js.map +1 -1
- package/lib/commands/exportAccounts.d.ts +1 -1
- package/lib/commands/exportAccounts.d.ts.map +1 -1
- package/lib/commands/exportAccounts.js +8 -11
- package/lib/commands/exportAccounts.js.map +1 -1
- package/lib/commands/firmwareRepair.js +5 -5
- package/lib/commands/firmwareRepair.js.map +1 -1
- package/lib/commands/firmwareUpdate.d.ts.map +1 -1
- package/lib/commands/firmwareUpdate.js +20 -24
- package/lib/commands/firmwareUpdate.js.map +1 -1
- package/lib/commands/generateTestScanAccounts.js +4 -4
- package/lib/commands/generateTestScanAccounts.js.map +1 -1
- package/lib/commands/generateTestTransaction.d.ts.map +1 -1
- package/lib/commands/generateTestTransaction.js +4 -4
- package/lib/commands/generateTestTransaction.js.map +1 -1
- package/lib/commands/genuineCheck.d.ts.map +1 -1
- package/lib/commands/genuineCheck.js +4 -4
- package/lib/commands/genuineCheck.js.map +1 -1
- package/lib/commands/getAddress.d.ts.map +1 -1
- package/lib/commands/getAddress.js +8 -8
- package/lib/commands/getAddress.js.map +1 -1
- package/lib/commands/getBatteryStatus.d.ts.map +1 -1
- package/lib/commands/getBatteryStatus.js +5 -5
- package/lib/commands/getBatteryStatus.js.map +1 -1
- package/lib/commands/getDeviceRunningMode.d.ts.map +1 -1
- package/lib/commands/getDeviceRunningMode.js +6 -6
- package/lib/commands/getDeviceRunningMode.js.map +1 -1
- package/lib/commands/getTransactionStatus.d.ts.map +1 -1
- package/lib/commands/getTransactionStatus.js +9 -12
- package/lib/commands/getTransactionStatus.js.map +1 -1
- package/lib/commands/i18n.d.ts.map +1 -1
- package/lib/commands/i18n.js +7 -7
- package/lib/commands/i18n.js.map +1 -1
- package/lib/commands/liveData.d.ts.map +1 -1
- package/lib/commands/liveData.js +10 -10
- package/lib/commands/liveData.js.map +1 -1
- package/lib/commands/managerListApps.d.ts +8 -1
- package/lib/commands/managerListApps.d.ts.map +1 -1
- package/lib/commands/managerListApps.js +14 -8
- package/lib/commands/managerListApps.js.map +1 -1
- package/lib/commands/portfolio.d.ts.map +1 -1
- package/lib/commands/portfolio.js +19 -23
- package/lib/commands/portfolio.js.map +1 -1
- package/lib/commands/proxy.d.ts +1 -1
- package/lib/commands/proxy.d.ts.map +1 -1
- package/lib/commands/proxy.js +29 -29
- package/lib/commands/proxy.js.map +1 -1
- package/lib/commands/receive.d.ts.map +1 -1
- package/lib/commands/receive.js +7 -8
- package/lib/commands/receive.js.map +1 -1
- package/lib/commands/repl.js +4 -4
- package/lib/commands/repl.js.map +1 -1
- package/lib/commands/satstack.d.ts.map +1 -1
- package/lib/commands/satstack.js +18 -21
- package/lib/commands/satstack.js.map +1 -1
- package/lib/commands/satstackStatus.js +4 -4
- package/lib/commands/satstackStatus.js.map +1 -1
- package/lib/commands/scanDescriptors.js +3 -3
- package/lib/commands/scanDescriptors.js.map +1 -1
- package/lib/commands/send.d.ts.map +1 -1
- package/lib/commands/send.js +11 -14
- package/lib/commands/send.js.map +1 -1
- package/lib/commands/signMessage.d.ts.map +1 -1
- package/lib/commands/signMessage.js +9 -11
- package/lib/commands/signMessage.js.map +1 -1
- package/lib/commands/speculosList.js +4 -4
- package/lib/commands/speculosList.js.map +1 -1
- package/lib/commands/staxFetchAndRestoreDemo.d.ts.map +1 -1
- package/lib/commands/staxFetchAndRestoreDemo.js +16 -16
- package/lib/commands/staxFetchAndRestoreDemo.js.map +1 -1
- package/lib/commands/staxFetchImage.js +6 -6
- package/lib/commands/staxFetchImage.js.map +1 -1
- package/lib/commands/staxFetchImageHash.d.ts.map +1 -1
- package/lib/commands/staxFetchImageHash.js +4 -8
- package/lib/commands/staxFetchImageHash.js.map +1 -1
- package/lib/commands/staxLoadImage.d.ts.map +1 -1
- package/lib/commands/staxLoadImage.js +7 -7
- package/lib/commands/staxLoadImage.js.map +1 -1
- package/lib/commands/staxRemoveImage.d.ts.map +1 -1
- package/lib/commands/staxRemoveImage.js +4 -6
- package/lib/commands/staxRemoveImage.js.map +1 -1
- package/lib/commands/swap.d.ts.map +1 -1
- package/lib/commands/swap.js +37 -39
- package/lib/commands/swap.js.map +1 -1
- package/lib/commands/sync.d.ts.map +1 -1
- package/lib/commands/sync.js +9 -11
- package/lib/commands/sync.js.map +1 -1
- package/lib/commands/synchronousOnboarding.js +5 -5
- package/lib/commands/synchronousOnboarding.js.map +1 -1
- package/lib/commands/testDetectOpCollision.js +5 -5
- package/lib/commands/testDetectOpCollision.js.map +1 -1
- package/lib/commands/testGetTrustedInputFromTxHash.d.ts.map +1 -1
- package/lib/commands/testGetTrustedInputFromTxHash.js +16 -23
- package/lib/commands/testGetTrustedInputFromTxHash.js.map +1 -1
- package/lib/commands/user.js +3 -3
- package/lib/commands/user.js.map +1 -1
- package/lib/commands/version.d.ts.map +1 -1
- package/lib/commands/version.js +4 -5
- package/lib/commands/version.js.map +1 -1
- package/lib/commands/walletconnect.d.ts.map +1 -1
- package/lib/commands/walletconnect.js +19 -21
- package/lib/commands/walletconnect.js.map +1 -1
- package/lib/commands-index.d.ts +12 -5
- package/lib/commands-index.d.ts.map +1 -1
- package/lib/commands-index.js +62 -62
- package/lib/commands-index.js.map +1 -1
- package/lib/live-common-setup-base.js +13 -16
- package/lib/live-common-setup-base.js.map +1 -1
- package/lib/live-common-setup.d.ts.map +1 -1
- package/lib/live-common-setup.js +20 -21
- package/lib/live-common-setup.js.map +1 -1
- package/lib/qr.js +2 -2
- package/lib/qr.js.map +1 -1
- package/lib/scan.d.ts.map +1 -1
- package/lib/scan.js +28 -33
- package/lib/scan.js.map +1 -1
- package/lib/signedOperation.js +7 -7
- package/lib/signedOperation.js.map +1 -1
- package/lib/stream.js +3 -3
- package/lib/stream.js.map +1 -1
- package/lib/transaction.d.ts.map +1 -1
- package/lib/transaction.js +16 -18
- package/lib/transaction.js.map +1 -1
- package/package.json +18 -16
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
|
-
exports
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
var rxjs_1 = require("rxjs");
|
|
7
7
|
var deviceAccess_1 = require("@ledgerhq/live-common/hw/deviceAccess");
|
|
8
8
|
var getDeviceInfo_1 = __importDefault(require("@ledgerhq/live-common/hw/getDeviceInfo"));
|
|
9
9
|
var scan_1 = require("../scan");
|
|
10
|
-
exports
|
|
10
|
+
exports.default = {
|
|
11
11
|
args: [scan_1.deviceOpt],
|
|
12
12
|
job: function (_a) {
|
|
13
13
|
var device = _a.device;
|
|
14
|
-
return (0, deviceAccess_1.withDevice)(device || "")(function (t) { return (0, rxjs_1.from)((0, getDeviceInfo_1
|
|
15
|
-
}
|
|
14
|
+
return (0, deviceAccess_1.withDevice)(device || "")(function (t) { return (0, rxjs_1.from)((0, getDeviceInfo_1.default)(t)); });
|
|
15
|
+
},
|
|
16
16
|
};
|
|
17
17
|
//# sourceMappingURL=deviceInfo.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deviceInfo.js","sourceRoot":"","sources":["../../src/commands/deviceInfo.ts"],"names":[],"mappings":";;;;;AAAA,6BAA4B;AAC5B,sEAAmE;AACnE,yFAAmE;AACnE,gCAAoC;AACpC,
|
|
1
|
+
{"version":3,"file":"deviceInfo.js","sourceRoot":"","sources":["../../src/commands/deviceInfo.ts"],"names":[],"mappings":";;;;;AAAA,6BAA4B;AAC5B,sEAAmE;AACnE,yFAAmE;AACnE,gCAAoC;AACpC,kBAAe;IACb,IAAI,EAAE,CAAC,gBAAS,CAAC;IACjB,GAAG,EAAE,UAAC,EAIJ;YAHA,MAAM,YAAA;QAGD,OAAA,IAAA,yBAAU,EAAC,MAAM,IAAI,EAAE,CAAC,CAAC,UAAA,CAAC,IAAI,OAAA,IAAA,WAAI,EAAC,IAAA,uBAAa,EAAC,CAAC,CAAC,CAAC,EAAtB,CAAsB,CAAC;IAArD,CAAqD;CAC7D,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deviceSDKFirmwareUpdate.d.ts","sourceRoot":"","sources":["../../src/commands/deviceSDKFirmwareUpdate.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"deviceSDKFirmwareUpdate.d.ts","sourceRoot":"","sources":["../../src/commands/deviceSDKFirmwareUpdate.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;gBA0FY,MAAM;oBACF,MAAM;0BACA,OAAO;kBACf,OAAO;;;AA7BrB,wBA2CE"}
|
|
@@ -38,15 +38,16 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
38
38
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
39
39
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
40
40
|
};
|
|
41
|
-
exports
|
|
41
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
42
42
|
var invariant_1 = __importDefault(require("invariant"));
|
|
43
43
|
var rxjs_1 = require("rxjs");
|
|
44
44
|
var operators_1 = require("rxjs/operators");
|
|
45
|
-
|
|
46
|
-
|
|
45
|
+
// import type { DeviceInfo, FirmwareUpdateContext } from "@ledgerhq/types-live";
|
|
46
|
+
// import { UnknownMCU } from "@ledgerhq/errors";
|
|
47
|
+
// import ManagerAPI from "@ledgerhq/live-common/manager/api";
|
|
47
48
|
var network_1 = __importDefault(require("@ledgerhq/live-network/network"));
|
|
48
49
|
var env_1 = require("@ledgerhq/live-common/env");
|
|
49
|
-
|
|
50
|
+
// import { getProviderId } from "@ledgerhq/live-common/manager/provider";
|
|
50
51
|
var deviceAccess_1 = require("@ledgerhq/live-common/hw/deviceAccess");
|
|
51
52
|
var getDeviceInfo_1 = __importDefault(require("@ledgerhq/live-common/hw/getDeviceInfo"));
|
|
52
53
|
var updateFirmware_1 = require("@ledgerhq/live-common/deviceSDK/actions/updateFirmware");
|
|
@@ -55,9 +56,9 @@ var listFirmwareOSU = function () { return __awaiter(void 0, void 0, void 0, fun
|
|
|
55
56
|
var data;
|
|
56
57
|
return __generator(this, function (_a) {
|
|
57
58
|
switch (_a.label) {
|
|
58
|
-
case 0: return [4 /*yield*/, (0, network_1
|
|
59
|
+
case 0: return [4 /*yield*/, (0, network_1.default)({
|
|
59
60
|
method: "GET",
|
|
60
|
-
url: "".concat((0, env_1.getEnv)("MANAGER_API_BASE"), "/firmware_osu_versions")
|
|
61
|
+
url: "".concat((0, env_1.getEnv)("MANAGER_API_BASE"), "/firmware_osu_versions"),
|
|
61
62
|
})];
|
|
62
63
|
case 1:
|
|
63
64
|
data = (_a.sent()).data;
|
|
@@ -65,80 +66,71 @@ var listFirmwareOSU = function () { return __awaiter(void 0, void 0, void 0, fun
|
|
|
65
66
|
}
|
|
66
67
|
});
|
|
67
68
|
}); };
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
shouldFlashMCU = !final.mcu_versions.includes(currentMcuVersion.id);
|
|
105
|
-
return [2 /*return*/, {
|
|
106
|
-
final: final,
|
|
107
|
-
osu: osu,
|
|
108
|
-
shouldFlashMCU: shouldFlashMCU
|
|
109
|
-
}];
|
|
110
|
-
}
|
|
111
|
-
});
|
|
112
|
-
}); };
|
|
69
|
+
// FIXME: NOT USED AS OF NOW
|
|
70
|
+
// const customGetLatestFirmwareForDevice = async (
|
|
71
|
+
// deviceInfo: DeviceInfo,
|
|
72
|
+
// osuVersion: string,
|
|
73
|
+
// ): Promise<FirmwareUpdateContext | null | undefined> => {
|
|
74
|
+
// const mcusPromise = ManagerAPI.getMcus();
|
|
75
|
+
// // Get device infos from targetId
|
|
76
|
+
// const deviceVersion = await ManagerAPI.getDeviceVersion(
|
|
77
|
+
// deviceInfo.targetId,
|
|
78
|
+
// getProviderId(deviceInfo),
|
|
79
|
+
// );
|
|
80
|
+
// let osu;
|
|
81
|
+
// if (deviceInfo.isOSU) {
|
|
82
|
+
// osu = await ManagerAPI.getCurrentOSU({
|
|
83
|
+
// deviceId: deviceVersion.id,
|
|
84
|
+
// provider: getProviderId(deviceInfo),
|
|
85
|
+
// version: deviceInfo.version,
|
|
86
|
+
// });
|
|
87
|
+
// } else {
|
|
88
|
+
// const data = await listFirmwareOSU();
|
|
89
|
+
// osu = data.find(d => d.device_versions.includes(deviceVersion.id) && d.name === osuVersion);
|
|
90
|
+
// }
|
|
91
|
+
// if (!osu) {
|
|
92
|
+
// return null;
|
|
93
|
+
// }
|
|
94
|
+
// const final = await ManagerAPI.getFinalFirmwareById(osu.next_se_firmware_final_version);
|
|
95
|
+
// const mcus = await mcusPromise;
|
|
96
|
+
// const currentMcuVersion = mcus.find(mcu => mcu.name === deviceInfo.mcuVersion);
|
|
97
|
+
// if (!currentMcuVersion) throw new UnknownMCU();
|
|
98
|
+
// const shouldFlashMCU = !final.mcu_versions.includes(currentMcuVersion.id);
|
|
99
|
+
// return {
|
|
100
|
+
// final,
|
|
101
|
+
// osu,
|
|
102
|
+
// shouldFlashMCU,
|
|
103
|
+
// };
|
|
104
|
+
// };
|
|
113
105
|
var disclaimer = "this is a developer feature that allow to flash anything, we are not responsible of your actions, by flashing your device you might reset your seed or block your device";
|
|
114
|
-
exports
|
|
106
|
+
exports.default = {
|
|
115
107
|
description: "Perform a firmware update",
|
|
116
108
|
args: [
|
|
117
109
|
scan_1.deviceOpt,
|
|
118
110
|
{
|
|
119
111
|
name: "to-my-own-risk",
|
|
120
112
|
type: Boolean,
|
|
121
|
-
desc: disclaimer
|
|
113
|
+
desc: disclaimer,
|
|
122
114
|
},
|
|
123
115
|
{
|
|
124
116
|
name: "osuVersion",
|
|
125
117
|
type: String,
|
|
126
|
-
desc: "(to your own risk) provide yourself an OSU version to flash the device with"
|
|
118
|
+
desc: "(to your own risk) provide yourself an OSU version to flash the device with",
|
|
127
119
|
},
|
|
128
120
|
{
|
|
129
121
|
name: "listOSUs",
|
|
130
122
|
type: Boolean,
|
|
131
|
-
desc: "list all available OSUs (for all devices, beta and prod versions)"
|
|
123
|
+
desc: "list all available OSUs (for all devices, beta and prod versions)",
|
|
132
124
|
},
|
|
133
125
|
],
|
|
134
126
|
job: function (_a) {
|
|
135
127
|
var device = _a.device, osuVersion = _a.osuVersion, toMyOwnRisk = _a["to-my-own-risk"], listOSUs = _a.listOSUs;
|
|
136
|
-
return ((0, invariant_1
|
|
128
|
+
return ((0, invariant_1.default)(!osuVersion || toMyOwnRisk, "--to-my-own-risk is required: " + disclaimer),
|
|
137
129
|
listOSUs
|
|
138
130
|
? (0, rxjs_1.from)(listFirmwareOSU()).pipe((0, operators_1.mergeMap)(function (d) { return (0, rxjs_1.from)(d.map(function (d) { return d.name; })); }))
|
|
139
|
-
: (0, deviceAccess_1.withDevice)(device || "")(function (t) { return (0, rxjs_1.from)((0, getDeviceInfo_1
|
|
131
|
+
: (0, deviceAccess_1.withDevice)(device || "")(function (t) { return (0, rxjs_1.from)((0, getDeviceInfo_1.default)(t)); }).pipe((0, operators_1.mergeMap)(function () {
|
|
140
132
|
return (0, rxjs_1.concat)((0, rxjs_1.of)("Attempting to install firmware"), (0, updateFirmware_1.updateFirmwareAction)({ deviceId: device || "" }));
|
|
141
133
|
})));
|
|
142
|
-
}
|
|
134
|
+
},
|
|
143
135
|
};
|
|
144
136
|
//# sourceMappingURL=deviceSDKFirmwareUpdate.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deviceSDKFirmwareUpdate.js","sourceRoot":"","sources":["../../src/commands/deviceSDKFirmwareUpdate.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wDAAkC;AAClC,6BAAwC;AACxC,4CAA0C;
|
|
1
|
+
{"version":3,"file":"deviceSDKFirmware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1 = require("@ledgerhq/live-common/deviceSDK/actions/getDeviceInfo");
|
|
5
5
|
var scan_1 = require("../scan");
|
|
6
|
-
exports
|
|
6
|
+
exports.default = {
|
|
7
7
|
description: "Device SDK: get device info",
|
|
8
8
|
args: [scan_1.deviceOpt],
|
|
9
9
|
job: function (_a) {
|
|
10
10
|
var device = _a.device;
|
|
11
11
|
return new rxjs_1.Observable(function (o) {
|
|
12
12
|
return (0, getDeviceInfo_1.getDeviceInfoAction)({
|
|
13
|
-
deviceId: device !== null && device !== void 0 ? device : ""
|
|
13
|
+
deviceId: device !== null && device !== void 0 ? device : "",
|
|
14
14
|
}).subscribe(o);
|
|
15
15
|
});
|
|
16
|
-
}
|
|
16
|
+
},
|
|
17
17
|
};
|
|
18
18
|
//# sourceMappingURL=deviceSDKGetDeviceInfo.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deviceSDKGetDeviceInfo.js","sourceRoot":"","sources":["../../src/commands/deviceSDKGetDeviceInfo.ts"],"names":[],"mappings":";;AAAA,6BAAkC;AAClC,uFAA4F;AAC5F,gCAAoC;AAEpC,
|
|
1
|
+
{"version":3,"file":"deviceSDKGetDeviceInfo.js","sourceRoot":"","sources":["../../src/commands/deviceSDKGetDeviceInfo.ts"],"names":[],"mappings":";;AAAA,6BAAkC;AAClC,uFAA4F;AAC5F,gCAAoC;AAEpC,kBAAe;IACb,WAAW,EAAE,6BAA6B;IAC1C,IAAI,EAAE,CAAC,gBAAS,CAAC;IACjB,GAAG,EAAE,UAAC,EAIJ;YAHA,MAAM,YAAA;QAIN,OAAO,IAAI,iBAAU,CAAC,UAAA,CAAC;YACrB,OAAO,IAAA,mCAAmB,EAAC;gBACzB,QAAQ,EAAE,MAAM,aAAN,MAAM,cAAN,MAAM,GAAI,EAAE;aACvB,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;QAClB,CAAC,CAAC,CAAC;IACL,CAAC;CACF,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deviceSDKToggleOnboardingEarlyCheck.d.ts","sourceRoot":"","sources":["../../src/commands/deviceSDKToggleOnboardingEarlyCheck.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"deviceSDKToggleOnboardingEarlyCheck.d.ts","sourceRoot":"","sources":["../../src/commands/deviceSDKToggleOnboardingEarlyCheck.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;;;;;;;;;;;;;;;;gBAmBtB,MAAM;oBACF,OAAO,GAAG,MAAM;;;AAhBhC,wBA8BE"}
|
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
exports
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
var rxjs_1 = require("rxjs");
|
|
4
4
|
var toggleOnboardingEarlyCheck_1 = require("@ledgerhq/live-common/deviceSDK/actions/toggleOnboardingEarlyCheck");
|
|
5
5
|
var scan_1 = require("../scan");
|
|
6
|
-
exports
|
|
6
|
+
exports.default = {
|
|
7
7
|
description: "Device SDK: toggle the onboarding early checks",
|
|
8
|
-
args: [
|
|
8
|
+
args: [
|
|
9
|
+
scan_1.deviceOpt,
|
|
9
10
|
{
|
|
10
11
|
name: "toggleType",
|
|
11
12
|
alias: "t",
|
|
12
13
|
desc: "'enter' or 'exit' the onboarding early check",
|
|
13
|
-
type: String
|
|
14
|
+
type: String,
|
|
14
15
|
},
|
|
15
16
|
],
|
|
16
17
|
job: function (_a) {
|
|
@@ -22,9 +23,9 @@ exports["default"] = {
|
|
|
22
23
|
}
|
|
23
24
|
return (0, toggleOnboardingEarlyCheck_1.toggleOnboardingEarlyCheckAction)({
|
|
24
25
|
deviceId: device !== null && device !== void 0 ? device : "",
|
|
25
|
-
toggleType: toggleType !== null && toggleType !== void 0 ? toggleType : "enter"
|
|
26
|
+
toggleType: toggleType !== null && toggleType !== void 0 ? toggleType : "enter",
|
|
26
27
|
}).subscribe(o);
|
|
27
28
|
});
|
|
28
|
-
}
|
|
29
|
+
},
|
|
29
30
|
};
|
|
30
31
|
//# sourceMappingURL=deviceSDKToggleOnboardingEarlyCheck.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deviceSDKToggleOnboardingEarlyCheck.js","sourceRoot":"","sources":["../../src/commands/deviceSDKToggleOnboardingEarlyCheck.ts"],"names":[],"mappings":";;AAAA,6BAAkC;AAClC,iHAAsH;AACtH,gCAAoC;AAEpC,
|
|
1
|
+
{"version":3,"file":"deviceSDKToggleOnboardingEarlyCheck.js","sourceRoot":"","sources":["../../src/commands/deviceSDKToggleOnboardingEarlyCheck.ts"],"names":[],"mappings":";;AAAA,6BAAkC;AAClC,iHAAsH;AACtH,gCAAoC;AAEpC,kBAAe;IACb,WAAW,EAAE,gDAAgD;IAC7D,IAAI,EAAE;QACJ,gBAAS;QACT;YACE,IAAI,EAAE,YAAY;YAClB,KAAK,EAAE,GAAG;YACV,IAAI,EAAE,8CAA8C;YACpD,IAAI,EAAE,MAAM;SACb;KACF;IACD,GAAG,EAAE,UAAC,EAMJ;YALA,MAAM,YAAA,EACN,UAAU,gBAAA;QAKV,OAAO,IAAI,iBAAU,CAAC,UAAA,CAAC;YACrB,IAAI,UAAU,IAAI,CAAC,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC,QAAQ,CAAC,UAAU,CAAC,EAAE;gBACzD,CAAC,CAAC,IAAI,CAAC,6EAA6D,UAAU,CAAE,CAAC,CAAC;gBAClF,OAAO;aACR;YAED,OAAO,IAAA,6DAAgC,EAAC;gBACtC,QAAQ,EAAE,MAAM,aAAN,MAAM,cAAN,MAAM,GAAI,EAAE;gBACtB,UAAU,EAAE,UAAU,aAAV,UAAU,cAAV,UAAU,GAAI,OAAO;aAClC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;QAClB,CAAC,CAAC,CAAC;IACL,CAAC;CACF,CAAC"}
|
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
|
-
exports
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
var rxjs_1 = require("rxjs");
|
|
7
7
|
var deviceAccess_1 = require("@ledgerhq/live-common/hw/deviceAccess");
|
|
8
8
|
var getVersion_1 = __importDefault(require("@ledgerhq/live-common/hw/getVersion"));
|
|
9
9
|
var scan_1 = require("../scan");
|
|
10
|
-
exports
|
|
10
|
+
exports.default = {
|
|
11
11
|
args: [scan_1.deviceOpt],
|
|
12
12
|
job: function (_a) {
|
|
13
13
|
var device = _a.device;
|
|
14
|
-
return (0, deviceAccess_1.withDevice)(device || "")(function (t) { return (0, rxjs_1.from)((0, getVersion_1
|
|
15
|
-
}
|
|
14
|
+
return (0, deviceAccess_1.withDevice)(device || "")(function (t) { return (0, rxjs_1.from)((0, getVersion_1.default)(t)); });
|
|
15
|
+
},
|
|
16
16
|
};
|
|
17
17
|
//# sourceMappingURL=deviceVersion.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deviceVersion.js","sourceRoot":"","sources":["../../src/commands/deviceVersion.ts"],"names":[],"mappings":";;;;;AAAA,6BAA4B;AAC5B,sEAAmE;AACnE,mFAA6D;AAC7D,gCAAoC;AACpC,
|
|
1
|
+
{"version":3,"file":"deviceVersion.js","sourceRoot":"","sources":["../../src/commands/deviceVersion.ts"],"names":[],"mappings":";;;;;AAAA,6BAA4B;AAC5B,sEAAmE;AACnE,mFAA6D;AAC7D,gCAAoC;AACpC,kBAAe;IACb,IAAI,EAAE,CAAC,gBAAS,CAAC;IACjB,GAAG,EAAE,UAAC,EAIJ;YAHA,MAAM,YAAA;QAGD,OAAA,IAAA,yBAAU,EAAC,MAAM,IAAI,EAAE,CAAC,CAAC,UAAA,CAAC,IAAI,OAAA,IAAA,WAAI,EAAC,IAAA,oBAAU,EAAC,CAAC,CAAC,CAAC,EAAnB,CAAmB,CAAC;IAAlD,CAAkD;CAC1D,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"discoverDevices.d.ts","sourceRoot":"","sources":["../../src/commands/discoverDevices.ts"],"names":[],"mappings":";;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"discoverDevices.d.ts","sourceRoot":"","sources":["../../src/commands/discoverDevices.ts"],"names":[],"mappings":";;;;;;;;;;;;;gBAuBY,MAAM;qBACD,OAAO;;;AApBxB,wBA2DE"}
|
|
@@ -35,29 +35,27 @@ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
|
35
35
|
}
|
|
36
36
|
return to.concat(ar || Array.prototype.slice.call(from));
|
|
37
37
|
};
|
|
38
|
-
exports
|
|
38
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
39
|
var operators_1 = require("rxjs/operators");
|
|
40
40
|
var index_1 = require("@ledgerhq/live-common/hw/index");
|
|
41
|
-
exports
|
|
41
|
+
exports.default = {
|
|
42
42
|
args: [
|
|
43
43
|
{
|
|
44
44
|
name: "module",
|
|
45
45
|
alias: "m",
|
|
46
46
|
type: String,
|
|
47
|
-
desc: "filter a specific module (either hid | ble)"
|
|
47
|
+
desc: "filter a specific module (either hid | ble)",
|
|
48
48
|
},
|
|
49
49
|
{
|
|
50
50
|
name: "interactive",
|
|
51
51
|
alias: "i",
|
|
52
52
|
type: Boolean,
|
|
53
|
-
desc: "interactive mode that accumulate the events instead of showing them"
|
|
53
|
+
desc: "interactive mode that accumulate the events instead of showing them",
|
|
54
54
|
},
|
|
55
55
|
],
|
|
56
56
|
job: function (_a) {
|
|
57
57
|
var module = _a.module, interactive = _a.interactive;
|
|
58
|
-
var events = (0, index_1.discoverDevices)(function (m) {
|
|
59
|
-
return !module ? true : module.split(",").includes(m.id);
|
|
60
|
-
});
|
|
58
|
+
var events = (0, index_1.discoverDevices)(function (m) { return (!module ? true : module.split(",").includes(m.id)); });
|
|
61
59
|
if (!interactive)
|
|
62
60
|
return events;
|
|
63
61
|
return events
|
|
@@ -84,11 +82,7 @@ exports["default"] = {
|
|
|
84
82
|
.pipe((0, operators_1.tap)(function () {
|
|
85
83
|
// eslint-disable-next-line no-console
|
|
86
84
|
console.clear();
|
|
87
|
-
}), (0, operators_1.map)(function (acc) {
|
|
88
|
-
|
|
89
|
-
.map(function (o) { return "".concat((o.name || "(no name)").padEnd(40), " ").concat(o.id); })
|
|
90
|
-
.join("\n");
|
|
91
|
-
}));
|
|
92
|
-
}
|
|
85
|
+
}), (0, operators_1.map)(function (acc) { return acc.map(function (o) { return "".concat((o.name || "(no name)").padEnd(40), " ").concat(o.id); }).join("\n"); }));
|
|
86
|
+
},
|
|
93
87
|
};
|
|
94
88
|
//# sourceMappingURL=discoverDevices.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"discoverDevices.js","sourceRoot":"","sources":["../../src/commands/discoverDevices.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,4CAA0D;AAC1D,wDAAiE;AAGjE,
|
|
1
|
+
{"version":3,"file":"discoverDevices.js","sourceRoot":"","sources":["../../src/commands/discoverDevices.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,4CAA0D;AAC1D,wDAAiE;AAGjE,kBAAe;IACb,IAAI,EAAE;QACJ;YACE,IAAI,EAAE,QAAQ;YACd,KAAK,EAAE,GAAG;YACV,IAAI,EAAE,MAAM;YACZ,IAAI,EAAE,6CAA6C;SACpD;QACD;YACE,IAAI,EAAE,aAAa;YACnB,KAAK,EAAE,GAAG;YACV,IAAI,EAAE,OAAO;YACb,IAAI,EAAE,qEAAqE;SAC5E;KACF;IACD,GAAG,EAAE,UAAC,EAMJ;YALA,MAAM,YAAA,EACN,WAA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C,UAAA,GAAG,IAAI,OAAA,GAAG,CAAC,GAAG,CAAC,UAAA,CAAC,IAAI,OAAA,UAAG,CAAC,CAAC,CAAC,IAAI,IAAI,WAAW,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,cAAI,CAAC,CAAC,EAAE,CAAE,EAA/C,CAA+C,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,EAAxE,CAAwE,CAAC,CACrF,CAAC;IACN,CAAC;CACF,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"envs.d.ts","sourceRoot":"","sources":["../../src/commands/envs.ts"],"names":[],"mappings":";;;;;AAGA,
|
|
1
|
+
{"version":3,"file":"envs.d.ts","sourceRoot":"","sources":["../../src/commands/envs.ts"],"names":[],"mappings":";;;;;AAGA,wBAOE"}
|
package/lib/commands/envs.js
CHANGED
|
@@ -1,15 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
exports
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
var rxjs_1 = require("rxjs");
|
|
4
4
|
var operators_1 = require("rxjs/operators");
|
|
5
5
|
var env_1 = require("@ledgerhq/live-common/env");
|
|
6
|
-
exports
|
|
6
|
+
exports.default = {
|
|
7
7
|
description: "Print available environment variables",
|
|
8
8
|
args: [],
|
|
9
9
|
job: function () {
|
|
10
|
-
return (0, rxjs_1.from)((0, env_1.getAllEnvNames)()).pipe((0, operators_1.map)(function (name) {
|
|
11
|
-
|
|
12
|
-
}));
|
|
13
|
-
}
|
|
10
|
+
return (0, rxjs_1.from)((0, env_1.getAllEnvNames)()).pipe((0, operators_1.map)(function (name) { return "# ".concat(name, " ").concat((0, env_1.getEnvDesc)(name), "\n").concat(name, "=").concat(JSON.stringify((0, env_1.getEnv)(name)), "\n"); }));
|
|
11
|
+
},
|
|
14
12
|
};
|
|
15
13
|
//# sourceMappingURL=envs.js.map
|
package/lib/commands/envs.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"envs.js","sourceRoot":"","sources":["../../src/commands/envs.ts"],"names":[],"mappings":";;AAAA,6BAA4B;AAC5B,4CAAqC;AACrC,iDAA+E;AAC/E,
|
|
1
|
+
{"version":3,"file":"envs.js","sourceRoot":"","sources":["../../src/commands/envs.ts"],"names":[],"mappings":";;AAAA,6BAA4B;AAC5B,4CAAqC;AACrC,iDAA+E;AAC/E,kBAAe;IACb,WAAW,EAAE,uCAAuC;IACpD,IAAI,EAAE,EAAE;IACR,GAAG,EAAE;QACH,OAAA,IAAA,WAAI,EAAC,IAAA,oBAAc,GAAE,CAAC,CAAC,IAAI,CACzB,IAAA,eAAG,EAAC,UAAA,IAAI,IAAI,OAAA,YAAK,IAAI,cAAI,IAAA,gBAAU,EAAC,IAAI,CAAC,eAAK,IAAI,cAAI,IAAI,CAAC,SAAS,CAAC,IAAA,YAAM,EAAC,IAAI,CAAC,CAAC,OAAI,EAA1E,CAA0E,CAAC,CACxF;IAFD,CAEC;CACJ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"estimateMaxSpendable.d.ts","sourceRoot":"","sources":["../../src/commands/estimateMaxSpendable.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"estimateMaxSpendable.d.ts","sourceRoot":"","sources":["../../src/commands/estimateMaxSpendable.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gBAehC,cAAc;;AAH5B,wBA6BE"}
|
|
@@ -24,7 +24,7 @@ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
|
24
24
|
}
|
|
25
25
|
return to.concat(ar || Array.prototype.slice.call(from));
|
|
26
26
|
};
|
|
27
|
-
exports
|
|
27
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
28
28
|
var rxjs_1 = require("rxjs");
|
|
29
29
|
var operators_1 = require("rxjs/operators");
|
|
30
30
|
var index_1 = require("@ledgerhq/live-common/bridge/index");
|
|
@@ -36,11 +36,11 @@ var format = function (account, value) {
|
|
|
36
36
|
var name = (0, index_2.getAccountName)(account);
|
|
37
37
|
var amount = (0, index_3.formatCurrencyUnit)(unit, value, {
|
|
38
38
|
showCode: true,
|
|
39
|
-
disableRounding: true
|
|
39
|
+
disableRounding: true,
|
|
40
40
|
});
|
|
41
41
|
return "".concat(name, ": ").concat(amount);
|
|
42
42
|
};
|
|
43
|
-
exports
|
|
43
|
+
exports.default = {
|
|
44
44
|
description: "estimate the max spendable of an account",
|
|
45
45
|
args: __spreadArray([], __read(scan_1.scanCommonOpts), false),
|
|
46
46
|
job: function (opts) {
|
|
@@ -49,17 +49,17 @@ exports["default"] = {
|
|
|
49
49
|
return rxjs_1.concat.apply(void 0, __spreadArray([(0, rxjs_1.from)(bridge
|
|
50
50
|
.estimateMaxSpendable({
|
|
51
51
|
account: account,
|
|
52
|
-
parentAccount: null
|
|
52
|
+
parentAccount: null,
|
|
53
53
|
})
|
|
54
54
|
.then(function (maxSpendable) { return format(account, maxSpendable); }))], __read((account.subAccounts || []).map(function (subAccount) {
|
|
55
55
|
return (0, rxjs_1.from)(bridge
|
|
56
56
|
.estimateMaxSpendable({
|
|
57
57
|
account: subAccount,
|
|
58
|
-
parentAccount: account
|
|
58
|
+
parentAccount: account,
|
|
59
59
|
})
|
|
60
60
|
.then(function (maxSpendable) { return " " + format(subAccount, maxSpendable); }));
|
|
61
61
|
})), false));
|
|
62
62
|
}));
|
|
63
|
-
}
|
|
63
|
+
},
|
|
64
64
|
};
|
|
65
65
|
//# sourceMappingURL=estimateMaxSpendable.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"estimateMaxSpendable.js","sourceRoot":"","sources":["../../src/commands/estimateMaxSpendable.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6BAAoC;AACpC,4CAA2C;AAC3C,4DAAsE;AACtE,
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;oBACnB,aAAa,EAAE,OAAO;iBACvB,CAAC;qBACD,IAAI,CAAC,UAAA,YAAY,IAAI,OAAA,IAAI,GAAG,MAAM,CAAC,UAAU,EAAE,YAAY,CAAC,EAAvC,CAAuC,CAAC,CACjE;YAPD,CAOC,CACF,WACD;QACJ,CAAC,CAAC,CACH;IAxBD,CAwBC;CACJ,CAAC"}
|
|
@@ -42,7 +42,7 @@ declare const _default: {
|
|
|
42
42
|
})[];
|
|
43
43
|
job: (opts: ScanCommonOpts & Partial<{
|
|
44
44
|
out: boolean;
|
|
45
|
-
}>) => import("rxjs").Observable<
|
|
45
|
+
}>) => import("rxjs").Observable<any>;
|
|
46
46
|
};
|
|
47
47
|
export default _default;
|
|
48
48
|
//# sourceMappingURL=exportAccounts.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exportAccounts.d.ts","sourceRoot":"","sources":["../../src/commands/exportAccounts.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gBAcpC,cAAc,GAClB,QAAQ;QACN,GAAG,EAAE,OAAO,CAAC;KACd,CAAC;;AAfR,
|
|
1
|
+
{"version":3,"file":"exportAccounts.d.ts","sourceRoot":"","sources":["../../src/commands/exportAccounts.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gBAcpC,cAAc,GAClB,QAAQ;QACN,GAAG,EAAE,OAAO,CAAC;KACd,CAAC;;AAfR,wBAwCE"}
|
|
@@ -24,21 +24,21 @@ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
|
24
24
|
}
|
|
25
25
|
return to.concat(ar || Array.prototype.slice.call(from));
|
|
26
26
|
};
|
|
27
|
-
exports
|
|
27
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
28
28
|
var rxjs_1 = require("rxjs");
|
|
29
29
|
var operators_1 = require("rxjs/operators");
|
|
30
30
|
var qrloop_1 = require("qrloop");
|
|
31
31
|
var cross_1 = require("@ledgerhq/live-common/cross");
|
|
32
32
|
var qr_1 = require("../qr");
|
|
33
33
|
var scan_1 = require("../scan");
|
|
34
|
-
exports
|
|
34
|
+
exports.default = {
|
|
35
35
|
description: "Export given accounts to Live QR or console for importing",
|
|
36
36
|
args: __spreadArray(__spreadArray([], __read(scan_1.scanCommonOpts), false), [
|
|
37
37
|
{
|
|
38
38
|
name: "out",
|
|
39
39
|
alias: "o",
|
|
40
40
|
type: Boolean,
|
|
41
|
-
desc: "output to console"
|
|
41
|
+
desc: "output to console",
|
|
42
42
|
},
|
|
43
43
|
], false),
|
|
44
44
|
job: function (opts) {
|
|
@@ -47,23 +47,20 @@ exports["default"] = {
|
|
|
47
47
|
accounts: accounts,
|
|
48
48
|
settings: {
|
|
49
49
|
pairExchanges: {},
|
|
50
|
-
currenciesSettings: {}
|
|
50
|
+
currenciesSettings: {},
|
|
51
51
|
},
|
|
52
52
|
exporterName: "ledger-live-cli",
|
|
53
|
-
exporterVersion: "0.0.0"
|
|
53
|
+
exporterVersion: "0.0.0",
|
|
54
54
|
});
|
|
55
55
|
var frames = (0, qrloop_1.dataToFrames)(data, 80, 4);
|
|
56
56
|
if (opts.out) {
|
|
57
57
|
return (0, rxjs_1.of)(Buffer.from(JSON.stringify(frames)).toString("base64"));
|
|
58
58
|
}
|
|
59
59
|
else {
|
|
60
|
-
var qrObservables_1 = frames.map(function (str) {
|
|
61
|
-
return (0, qr_1.asQR)(str).pipe((0, operators_1.shareReplay)());
|
|
62
|
-
});
|
|
60
|
+
var qrObservables_1 = frames.map(function (str) { return (0, qr_1.asQR)(str).pipe((0, operators_1.shareReplay)()); });
|
|
63
61
|
return (0, rxjs_1.interval)(300).pipe((0, operators_1.mergeMap)(function (i) { return qrObservables_1[i % qrObservables_1.length]; }));
|
|
64
62
|
}
|
|
65
|
-
}), (0, operators_1.tap)(function () { return console.clear(); })
|
|
66
|
-
|
|
67
|
-
}
|
|
63
|
+
}), (0, operators_1.tap)(function () { return console.clear(); }));
|
|
64
|
+
},
|
|
68
65
|
};
|
|
69
66
|
//# sourceMappingURL=exportAccounts.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exportAccounts.js","sourceRoot":"","sources":["../../src/commands/exportAccounts.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6BAAoC;AACpC,4CAAoE;AACpE,iCAAsC;AACtC,qDAAqD;AACrD,4BAA6B;AAC7B,gCAA+C;AAG/C,
|
|
1
|
+
{"version":3,"file":"exportAccounts.js","sourceRoot":"","sources":["../../src/commands/exportAccounts.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6BAAoC;AACpC,4CAAoE;AACpE,iCAAsC;AACtC,qDAAqD;AACrD,4BAA6B;AAC7B,gCAA+C;AAG/C,kBAAe;IACb,WAAW,EAAE,2DAA2D;IACxE,IAAI,yCACC,qBAAc;QACjB;YACE,IAAI,EAAE,KAAK;YACX,KAAK,EAAE,GAAG;YACV,IAAI,EAAE,OAAO;YACb,IAAI,EAAE,mBAAmB;SAC1B;aACF;IACD,GAAG,EAAE,UACH,IAGI;QAEJ,OAAA,IAAA,WAAI,EAAC,IAAI,CAAC,CAAC,IAAI,CACb,IAAA,kBAAM,EAAqB,UAAC,QAAQ,EAAE,OAAO,IAAK,OAAA,QAAQ,CAAC,MAAM,CAAC,OAAO,CAAC,EAAxB,CAAwB,EAAE,EAAE,CAAC,EAC/E,IAAA,oBAAQ,EAAC,UAAA,QAAQ;YACf,IAAM,IAAI,GAAG,IAAA,cAAM,EAAC;gBAClB,QAAQ,UAAA;gBACR,QAAQ,EAAE;oBACR,aAAa,EAAE,EAAE;oBACjB,kBAAkB,EAAE,EAAE;iBACvB;gBACD,YAAY,EAAE,iBAAiB;gBAC/B,eAAe,EAAE,OAAO;aACzB,CAAC,CAAC;YACH,IAAM,MAAM,GAAG,IAAA,qBAAY,EAAC,IAAI,EAAE,EAAE,EAAE,CAAC,CAAC,CAAC;YAEzC,IAAI,IAAI,CAAC,GAAG,EAAE;gBACZ,OAAO,IAAA,SAAE,EAAC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC;aACnE;iBAAM;gBACL,IAAM,eAAa,GAAG,MAAM,CAAC,GAAG,CAAC,UAAA,GAAG,IAAI,OAAA,IAAA,SAAI,EAAC,GAAG,CAAC,CAAC,IAAI,CAAC,IAAA,uBAAW,GAAE,CAAC,EAA7B,CAA6B,CAAC,CAAC;gBACvE,OAAO,IAAA,eAAQ,EAAC,GAAG,CAAC,CAAC,IAAI,CAAC,IAAA,oBAAQ,EAAC,UAAA,CAAC,IAAI,OAAA,eAAa,CAAC,CAAC,GAAG,eAAa,CAAC,MAAM,CAAC,EAAvC,CAAuC,CAAC,CAAC,CAAC;aACnF;QACH,CAAC,CAAC,EACF,IAAA,eAAG,EAAC,cAAM,OAAA,OAAO,CAAC,KAAK,EAAE,EAAf,CAAe,CAAC,CAC3B;IAtBD,CAsBC;CACJ,CAAC"}
|
|
@@ -2,22 +2,22 @@
|
|
|
2
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
|
-
exports
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
var firmwareUpdate_repair_1 = __importDefault(require("@ledgerhq/live-common/hw/firmwareUpdate-repair"));
|
|
7
7
|
var scan_1 = require("../scan");
|
|
8
|
-
exports
|
|
8
|
+
exports.default = {
|
|
9
9
|
description: "Repair a firmware update",
|
|
10
10
|
args: [
|
|
11
11
|
scan_1.deviceOpt,
|
|
12
12
|
{
|
|
13
13
|
name: "forceMCU",
|
|
14
14
|
type: String,
|
|
15
|
-
desc: "force a mcu version to install"
|
|
15
|
+
desc: "force a mcu version to install",
|
|
16
16
|
},
|
|
17
17
|
],
|
|
18
18
|
job: function (_a) {
|
|
19
19
|
var device = _a.device, forceMCU = _a.forceMCU;
|
|
20
|
-
return (0, firmwareUpdate_repair_1
|
|
21
|
-
}
|
|
20
|
+
return (0, firmwareUpdate_repair_1.default)(device || "", forceMCU);
|
|
21
|
+
},
|
|
22
22
|
};
|
|
23
23
|
//# sourceMappingURL=firmwareRepair.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"firmwareRepair.js","sourceRoot":"","sources":["../../src/commands/firmwareRepair.ts"],"names":[],"mappings":";;;;;AAAA,yGAAkF;AAClF,gCAAoC;AACpC,
|
|
1
|
+
{"version":3,"file":"firmwareRepair.js","sourceRoot":"","sources":["../../src/commands/firmwareRepair.ts"],"names":[],"mappings":";;;;;AAAA,yGAAkF;AAClF,gCAAoC;AACpC,kBAAe;IACb,WAAW,EAAE,0BAA0B;IACvC,IAAI,EAAE;QACJ,gBAAS;QACT;YACE,IAAI,EAAE,UAAU;YAChB,IAAI,EAAE,MAAM;YACZ,IAAI,EAAE,gCAAgC;SACvC;KACF;IACD,GAAG,EAAE,UAAC,EAMJ;YALA,MAAM,YAAA,EACN,QAAQ,cAAA;QAIH,OAAA,IAAA,+BAAoB,EAAC,MAAM,IAAI,EAAE,EAAE,QAAQ,CAAC;IAA5C,CAA4C;CACpD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"firmwareUpdate.d.ts","sourceRoot":"","sources":["../../src/commands/firmwareUpdate.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"firmwareUpdate.d.ts","sourceRoot":"","sources":["../../src/commands/firmwareUpdate.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;gBA2FY,MAAM;oBACF,MAAM;0BACA,OAAO;kBACf,OAAO;;;AA7BrB,wBAoDE"}
|