From 4e3c9c02c84497a8a79d4414c61b169c6069f3af Mon Sep 17 00:00:00 2001 From: jcesarmobile Date: Thu, 5 Mar 2026 14:13:32 +0100 Subject: [PATCH] feat: prepopulate repository url --- src/prompt.ts | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/prompt.ts b/src/prompt.ts index 76d601f..3249d95 100644 --- a/src/prompt.ts +++ b/src/prompt.ts @@ -52,16 +52,17 @@ export const gatherDetails = (initialOptions: Options): Promise => }, { type: 'text', - name: 'repo', - message: `What is the repository URL for your plugin?\n`, - validate: VALIDATORS.repo, + name: 'author', + message: `${kleur.reset('(optional)')} ${kleur.bold('Who is the author of this plugin?')}\n`, + validate: VALIDATORS.author, format: (value) => value.trim(), }, { type: 'text', - name: 'author', - message: `${kleur.reset('(optional)')} ${kleur.bold('Who is the author of this plugin?')}\n`, - validate: VALIDATORS.author, + name: 'repo', + message: `What is the repository URL for your plugin?\n`, + initial: (_prev, values) => `https://github.com/${values.author}/${values.dir}`, + validate: VALIDATORS.repo, format: (value) => value.trim(), }, {