clishop 1.4.5 → 1.4.7
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/dist/index.js +23 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -856,7 +856,8 @@ async function runSetupWizard(emailArg) {
|
|
|
856
856
|
console.log();
|
|
857
857
|
console.log(chalk4.bold.cyan(" W E L C O M E T O C L I S H O P"));
|
|
858
858
|
console.log(chalk4.dim(" Order anything from your terminal."));
|
|
859
|
-
console.log(chalk4.dim(`
|
|
859
|
+
console.log(chalk4.dim(` npm: v${"1.4.7"}`));
|
|
860
|
+
console.log(chalk4.dim(` Build: ${"2026-04-04T18:17:20.412Z"}`));
|
|
860
861
|
console.log();
|
|
861
862
|
divider(chalk4.cyan);
|
|
862
863
|
console.log();
|
|
@@ -2142,6 +2143,25 @@ var STATUS_COLORS = {
|
|
|
2142
2143
|
delivered: chalk7.green,
|
|
2143
2144
|
cancelled: chalk7.red
|
|
2144
2145
|
};
|
|
2146
|
+
function printMissingAddressGuidance() {
|
|
2147
|
+
console.error();
|
|
2148
|
+
console.error(chalk7.red("\u2717 No delivery address is set for this agent."));
|
|
2149
|
+
console.error();
|
|
2150
|
+
console.error(chalk7.dim(" To buy something, you need a delivery address first."));
|
|
2151
|
+
console.error(chalk7.dim(" Ask your human for the delivery address, or if you already know their home address,"));
|
|
2152
|
+
console.error(chalk7.dim(" suggest it yourself in full and ask them to confirm that it is correct."));
|
|
2153
|
+
console.error();
|
|
2154
|
+
console.error(chalk7.bold(" Suggested format:"));
|
|
2155
|
+
console.error(chalk7.white(" First + Last Name"));
|
|
2156
|
+
console.error(chalk7.white(" Street + number"));
|
|
2157
|
+
console.error(chalk7.white(" City + ZIP code"));
|
|
2158
|
+
console.error(chalk7.white(" Country"));
|
|
2159
|
+
console.error(chalk7.white(" Phone number"));
|
|
2160
|
+
console.error();
|
|
2161
|
+
console.error(chalk7.dim(" Once confirmed, save it as the Home address with:"));
|
|
2162
|
+
console.error(chalk7.white(" clishop address add"));
|
|
2163
|
+
console.error();
|
|
2164
|
+
}
|
|
2145
2165
|
function registerOrderCommands(program2) {
|
|
2146
2166
|
const order = program2.command("order").description("Place and manage orders");
|
|
2147
2167
|
program2.command("buy <productIdOrNumber>").description("Quick-buy a product (use product ID or search result number like 1, 2, 3)").option("-q, --quantity <qty>", "Quantity", parseInt, 1).option("--address <id>", "Shipping address ID (uses agent default if omitted)").option("--payment <id>", "Payment method ID (uses agent default if omitted)").option("-y, --yes", "Skip confirmation prompt").action(async (productIdOrNumber, opts) => {
|
|
@@ -2182,7 +2202,7 @@ function registerOrderCommands(program2) {
|
|
|
2182
2202
|
}
|
|
2183
2203
|
}
|
|
2184
2204
|
if (!addressId) {
|
|
2185
|
-
|
|
2205
|
+
printMissingAddressGuidance();
|
|
2186
2206
|
process.exitCode = 1;
|
|
2187
2207
|
return;
|
|
2188
2208
|
}
|
|
@@ -4071,7 +4091,7 @@ function registerDoctorCommand(program2) {
|
|
|
4071
4091
|
|
|
4072
4092
|
// src/index.ts
|
|
4073
4093
|
var program = new Command();
|
|
4074
|
-
program.name("clishop").version("1.4.
|
|
4094
|
+
program.name("clishop").version("1.4.7").description(
|
|
4075
4095
|
chalk16.bold("CLISHOP") + ` \u2014 Order anything from your terminal.
|
|
4076
4096
|
|
|
4077
4097
|
Run 'clishop setup' to get started with a single payment link.
|