shellmail 1.0.3 → 1.0.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.
Files changed (2) hide show
  1. package/dist/index.js +13 -7
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -20,6 +20,7 @@ program
20
20
  .description("Create a new ShellMail address interactively")
21
21
  .option("-l, --local <name>", "Local part of email address")
22
22
  .option("-r, --recovery <email>", "Recovery email address")
23
+ .option("-a, --auto", "Auto-generate a random address")
23
24
  .action(async (options) => {
24
25
  console.log(chalk.bold("\nšŸ“§ ShellMail Setup\n"));
25
26
  let local = options.local;
@@ -44,14 +45,20 @@ program
44
45
  // Loop until we get a valid address
45
46
  const api = new ShellMailAPI();
46
47
  let result = null;
48
+ // If --auto flag, skip the name prompt
49
+ if (options.auto) {
50
+ local = "auto";
51
+ }
47
52
  while (!result) {
48
53
  if (!local) {
49
54
  const answers = await inquirer.prompt([
50
55
  {
51
56
  type: "input",
52
57
  name: "local",
53
- message: `Choose your address:\n ${chalk.gray("_")}${chalk.cyan("@shellmail.ai")}\n `,
58
+ message: `Choose your address (or type "auto" for random):\n ${chalk.gray("_")}${chalk.cyan("@shellmail.ai")}\n `,
54
59
  validate: (input) => {
60
+ if (input === "auto")
61
+ return true;
55
62
  if (!input || input.length < 2)
56
63
  return "Must be at least 2 characters";
57
64
  if (!/^[a-z0-9][a-z0-9._-]*[a-z0-9]$/i.test(input) && input.length > 2) {
@@ -110,12 +117,11 @@ program
110
117
  // Show OpenClaw integration snippet
111
118
  console.log(chalk.bold("─".repeat(50)));
112
119
  console.log(chalk.bold("\nOpenClaw Integration\n"));
113
- console.log(chalk.gray("Add this to your openclaw.json:\n"));
114
- console.log(chalk.cyan(`"shellmail": {
115
- "apiUrl": "https://shellmail.ai",
116
- "token": "${result.token}"
117
- }`));
118
- console.log(chalk.gray("\n(inside skills.entries)\n"));
120
+ console.log(chalk.gray("Install the skill from ClawHub:\n"));
121
+ console.log(chalk.cyan(" clawhub install aaronbatchelder/shellmail\n"));
122
+ console.log(chalk.gray("Then set your token:\n"));
123
+ console.log(chalk.cyan(` export SHELLMAIL_TOKEN="${result.token}"\n`));
124
+ console.log(chalk.gray("Or add to your openclaw.json under skills.entries.shellmail.env\n"));
119
125
  // Show CLI commands
120
126
  console.log(chalk.bold("─".repeat(50)));
121
127
  console.log(chalk.bold("\nCLI Commands\n"));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shellmail",
3
- "version": "1.0.3",
3
+ "version": "1.0.5",
4
4
  "description": "CLI for ShellMail - Email for AI agents",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",