From af84b95b268a330d16c284f4d8426ba39e5eb84c Mon Sep 17 00:00:00 2001 From: Bauke Date: Mon, 6 Mar 2023 19:08:28 +0100 Subject: [PATCH] Add prompting for destination. --- .bauke/scripts/bulk/move.ts | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.bauke/scripts/bulk/move.ts b/.bauke/scripts/bulk/move.ts index e2a2dd9..2aacd19 100644 --- a/.bauke/scripts/bulk/move.ts +++ b/.bauke/scripts/bulk/move.ts @@ -27,7 +27,18 @@ async function actionHandler( continue; } - console.log(file); + const filename = file.name; + const { destination } = await prompt.prompt([{ + type: prompt.Input, + name: "destination", + message: `${filename} Destination:`, + }]); + + if (destination === undefined || destination === "") { + continue; + } + + console.log(filename, destination); } } }