1 | #!/usr/bin/env node
|
2 | "use strict";
|
3 | Object.defineProperty(exports, "__esModule", { value: true });
|
4 | const crypto = require("node:crypto");
|
5 | const yargs = require("yargs");
|
6 | const colors_1 = require("../colors");
|
7 | const script_1 = require("../script");
|
8 | (0, script_1.runScript)(() => {
|
9 | const { sizeBytes } = yargs.option('sizeBytes', {
|
10 | type: 'number',
|
11 | default: 256,
|
12 | }).argv;
|
13 | const key = crypto.randomBytes(sizeBytes).toString('base64');
|
14 | console.log((0, colors_1.dimGrey)('\nSECRET_ENCRYPTION_KEY:\n'));
|
15 | console.log(key, '\n');
|
16 | });
|