diff --git a/templates/script-command.template.js b/templates/script-command.template.js index e8e3a9e37..2a856f780 100755 --- a/templates/script-command.template.js +++ b/templates/script-command.template.js @@ -5,7 +5,7 @@ // Dependency: This script requires Nodejs. // Install Node: https://nodejs.org/en/download/ // -// Duplicate this file and remove ".template." from the filename to get started. +// Duplicate this file and remove ".template" from the filename to get started. // See full documentation here: https://github.com/raycast/script-commands // // Required parameters: @@ -24,6 +24,24 @@ // @raycast.author Your name // @raycast.authorURL An URL for one of your social medias +/* + + ABOUT THIS TEMPLATE: + + This template is meant to be a quick starting point for creating a script command using Nodejs. + + This template demonstrates the following ideas: + + * Extracting passed arguments. + * Using both required and optional arguments + * URI Encoding + * Outputting result to Raycast + * Opening a url using exec and the unix open command + * Use of destructuring + * Use of template literals + +*/ + const { exec } = require('child_process') // Use destructuring to grab arguments.