1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-06 02:15:48 +03:00
Files
2023-09-18 15:03:07 -04:00

14 lines
345 B
JavaScript

import yargs from 'yargs';
import { hideBin } from 'yargs/helpers';
import { randomBytes } from 'node:crypto';
const { size } = yargs(hideBin(process.argv))
.option('size', {
type: 'number',
default: 1024,
demandOption: true
})
.parseSync();
export const randomString = randomBytes(size).toString('ascii');