When you type an invalid command, the politeiagui-scripts toolkit displays the following message:
$ politeiagui-scripts invalid
/politeiagui/plugins-structure/packages/politeiagui-scripts/bin/politeiagui-scripts.js:68
throw new Error(`Unknown script "${script}".`);
^
Error: Unknown script "invalid".
at runScript (/Users/victorguedes/Documents/decred/politeiagui/plugins-structure/packages/politeiagui-scripts/bin/politeiagui-scripts.js:68:11)
at Object.<anonymous> (/Users/victorguedes/Documents/decred/politeiagui/plugins-structure/packages/politeiagui-scripts/bin/politeiagui-scripts.js:10:3)
at Module._compile (node:internal/modules/cjs/loader:1105:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1159:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:77:12)
at node:internal/main/run_main_module:17:47
We should simplify that and display a clean and objective message. Maybe something like this:
When you type an invalid command, the
politeiagui-scripts
toolkit displays the following message:We should simplify that and display a clean and objective message. Maybe something like this: