Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

persona

Package Overview
Dependencies
Maintainers
1
Versions
88
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

persona - npm Package Compare versions

Comparing version 0.1.0 to 0.1.2

lib/questions.json

1

index.js
#!/usr/bin/env node
process.chdir(__dirname);
var cli = require('./cli');

@@ -0,3 +1,3 @@

var async = require('async');
var readline = require('readline');
var q = require('./questions');
var rl = readline.createInterface({

@@ -8,2 +8,3 @@ input: process.stdin,

});
var questions = require('./questions.json');
var answers = {

@@ -33,10 +34,28 @@ profile: {

process.stdout.write("Welcome to the persona creator!\n");
process.stdout.write("Welcome to the persona creator!\n\n");
q.section("1.1 - Demographic Profile");
q.question("What is the name of your persona?", rl, function (a) {
answers.profile.demo.name = a;
q.question("What is the age of your persona?", rl, function (a) {
answers.profile.demo.age = a;
});
async.eachSeries(questions.q, function (e, cb) {
if (e.type === "s") {
process.stdout.write(e.name + "\n");
cb();
} else if (e.type === "q") {
rl.question(e.name + " ", function (a) {
if (e.cat) {
if (e.sub) {
if (e.to) {
answers[e.cat][e.sub][e.to] = a;
cb();
} else {
answers[e.cat][e.sub] = a;
cb();
}
} else {
answers[e.cat] = a;
cb();
}
}
});
}
}, function (err) {
if (err) throw err;
});
{
"name": "persona",
"version": "0.1.0",
"version": "0.1.2",
"description": "create personas from the command line",

@@ -24,5 +24,5 @@ "main": "index.js",

"dependencies": {
"bluebird": "^2.3.2",
"async": "^0.9.0",
"commander": "^2.3.0"
}
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc