nebulon-escrow-cli 0.1.0 → 0.8.5

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.
@@ -14,6 +14,7 @@ const {
14
14
  setActiveWallet,
15
15
  } = require("../wallets");
16
16
  const { banner, successMessage } = require("../ui");
17
+ const { VERSION } = require("../version");
17
18
 
18
19
  const isPromptCancel = (error) => {
19
20
  if (!error) {
@@ -122,6 +123,7 @@ const runInit = async (options = {}, capsuleName) => {
122
123
  try {
123
124
  if (!options.noBanner) {
124
125
  banner();
126
+ console.log(chalk.gray(`Version: ${VERSION}`));
125
127
  }
126
128
  if (capsuleName) {
127
129
  try {
@@ -138,21 +140,15 @@ const runInit = async (options = {}, capsuleName) => {
138
140
  let backendAnswer = { backendUrl: config.backendUrl };
139
141
  let backendSource = config.backendSource || "custom";
140
142
  let backendNetwork = null;
141
- let serverChoice = null;
142
- try {
143
- await getConfig((config.backendUrl || "http://174.138.42.117:3333").trim());
144
- serverChoice = await prompt({
145
- type: "select",
146
- name: "server",
147
- message: "Use official server or custom?",
148
- choices: [
149
- { name: "official", message: "Official server" },
150
- { name: "custom", message: "Custom server" },
151
- ],
152
- });
153
- } catch (error) {
154
- serverChoice = { server: "custom" };
155
- }
143
+ const serverChoice = await prompt({
144
+ type: "select",
145
+ name: "server",
146
+ message: "Use official server or custom?",
147
+ choices: [
148
+ { name: "official", message: "Official server" },
149
+ { name: "custom", message: "Custom server" },
150
+ ],
151
+ });
156
152
 
157
153
  if (serverChoice.server === "custom") {
158
154
  backendAnswer = await prompt({
package/src/constants.js CHANGED
@@ -53,13 +53,14 @@ const DEFAULT_CONFIG = {
53
53
  contractKeys: {},
54
54
  },
55
55
  auth: {
56
- token: null,
57
- wallet: null,
58
- handle: null,
59
- role: null,
60
- lastAuthAt: null,
61
- },
62
- };
56
+ token: null,
57
+ wallet: null,
58
+ handle: null,
59
+ role: null,
60
+ lastAuthAt: null,
61
+ },
62
+ skipPermissionChecks: false,
63
+ };
63
64
 
64
65
  module.exports = {
65
66
  DEFAULT_CONFIG,
package/src/version.js ADDED
@@ -0,0 +1,5 @@
1
+ const VERSION = "0.8.4";
2
+
3
+ module.exports = {
4
+ VERSION,
5
+ };