@airmoney-degn/airmoney-cli 0.25.0 → 0.25.1

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.
@@ -60,12 +60,20 @@ function getProjectPath(locationFolder) {
60
60
  return path_1.default.join(process.cwd(), locationFolder);
61
61
  }
62
62
  /**
63
- * Prompts user for confirmation when uploading from current directory
63
+ * Prompts user for confirmation when uploading from current directory.
64
+ * Web: warns that all files from the directory will be packed/uploaded.
65
+ * Native: only mentions building and uploading the package (binary + metadata + logo).
64
66
  */
65
- async function confirmUploadFromCurrentDirectory(projectPath) {
66
- (0, LogService_1.log)('⚠️ WARNING: You are about to upload all files from the current directory!').red();
67
- (0, LogService_1.log)(`Upload folder: ${path_1.default.resolve(projectPath)}`).white();
68
- (0, LogService_1.log)('To upload a specific folder, use: airmoney-cli upload -f <folder-path>').white();
67
+ async function confirmUploadFromCurrentDirectory(projectPath, appType) {
68
+ if (appType === 'Native') {
69
+ (0, LogService_1.log)(`Upload folder: ${path_1.default.resolve(projectPath)}`).white();
70
+ (0, LogService_1.log)('A package (binary + metadata + logo) will be built and uploaded.').white();
71
+ }
72
+ else {
73
+ (0, LogService_1.log)('⚠️ WARNING: You are about to upload all files from the current directory!').red();
74
+ (0, LogService_1.log)(`Upload folder: ${path_1.default.resolve(projectPath)}`).white();
75
+ (0, LogService_1.log)('To upload a specific folder, use: airmoney-cli upload -f <folder-path>').white();
76
+ }
69
77
  const answer = await inquirer_1.default.prompt([
70
78
  {
71
79
  type: 'confirm',
@@ -273,7 +281,8 @@ async function uploadCommand({ network, locationFolder, publicDir, packagePath:
273
281
  const projectPath = getProjectPath(locationFolder);
274
282
  // Prompt for confirmation if uploading from current directory
275
283
  if (!locationFolder) {
276
- const confirmed = await confirmUploadFromCurrentDirectory(projectPath);
284
+ const metaForConfirm = await (0, metadata_1.loadMetadata)(projectPath);
285
+ const confirmed = await confirmUploadFromCurrentDirectory(projectPath, metaForConfirm?.type);
277
286
  if (!confirmed) {
278
287
  (0, LogService_1.log)('Upload cancelled by user').yellow();
279
288
  return;
package/dist/config.json CHANGED
@@ -1,3 +1,3 @@
1
1
  {
2
- "version": "0.25.0"
2
+ "version": "0.25.1"
3
3
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@airmoney-degn/airmoney-cli",
3
- "version": "0.25.0",
3
+ "version": "0.25.1",
4
4
  "description": "airmoney-cli is a command-line interface tool designed to facilitate the development and management of decentralized applications (DApps) for Airmoney.",
5
5
  "publishConfig": {
6
6
  "access": "public"