Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[ux] Completed unifing grammatical person across all messaging. Fixed…

… many small inconsistencies in message formatting.
  • Loading branch information...
commit e1fe1bc1163524cde0e146fc6c45a06c28858018 1 parent 2b980eb
@Marak Marak authored
View
6 lib/jitsu.js
@@ -293,7 +293,7 @@ jitsu.showError = function (command, err, shallow, skip) {
if (err.result.result && err.result.result.error) {
if (err.result.result.error.stderr || err.result.result.error.stdout) {
jitsu.log.error('');
- jitsu.log.error('There was an error while attempting to start your application.');
+ jitsu.log.error('There was an error while attempting to start the app');
jitsu.log.error(err.result.result.error.message);
if (err.result.result.error.blame) {
jitsu.log.error(err.result.result.error.blame.message);
@@ -301,7 +301,7 @@ jitsu.showError = function (command, err, shallow, skip) {
jitsu.log.error('This type of error is usually a ' + err.result.result.error.blame.type + ' error.');
}
- jitsu.log.error('Error output from your application:');
+ jitsu.log.error('Error output from app:');
jitsu.log.error('');
if (err.result.result.error.stdout) {
err.result.result.error.stdout.split('\n').forEach(function (line) {
@@ -316,7 +316,7 @@ jitsu.showError = function (command, err, shallow, skip) {
}
}
else if (err.result.result.error.stack) {
- jitsu.log.error('There was an error while attempting to deploy your application.');
+ jitsu.log.error('There was an error while attempting to deploy the app');
jitsu.log.error('');
jitsu.log.error(err.result.result.error.message);
View
8 lib/jitsu/commands.js
@@ -11,15 +11,15 @@ jitsu.use(require('flatiron-cli-users'), {
before: {
login: function (details) {
if (!details || !details.username) {
- jitsu.log.warn('You will need to login to continue');
- jitsu.log.info('To login, you will need an activated nodejitsu account');
- jitsu.log.help('You can create an account using the ' + 'jitsu signup'.magenta + ' command');
+ jitsu.log.warn('Login is required to continue');
+ jitsu.log.info('To login, an activated nodejitsu account is required');
+ jitsu.log.help('To create a new account use the ' + 'jitsu signup'.magenta + ' command');
}
}
},
after: {
create: function (details) {
- jitsu.log.help('You must check the email we sent to ' + details.email.grey + ' for further activation instructions.');
+ jitsu.log.help('Please check for an email sent to ' + details.email.grey + ' for further activation instructions.');
}
}
});
View
10 lib/jitsu/commands/apps.js
@@ -11,7 +11,7 @@ var analyzer = require('require-analyzer'),
var apps = exports;
apps.usage = [
- '`jitsu apps *` commands allow you to work with your',
+ 'The `jitsu apps` command manages',
'Applications on Nodejitsu. Valid commands are:',
'',
'jitsu apps deploy',
@@ -42,8 +42,8 @@ apps.deploy = function (callback) {
var dir = process.cwd(), pkg;
function promptLogin () {
- jitsu.log.warn("You are not logged in.");
- jitsu.log.warn("Please authenticate first.");
+ jitsu.log.warn("No user is logged in");
+ jitsu.log.warn("Please authenticate");
jitsu.commands.users.login(function(){
jitsu.commands.apps.deploy(callback);
});
@@ -389,7 +389,7 @@ apps.view = function (name, callback) {
getAppName(function (err, pkg) {
if(err) {
jitsu.commands.list(function(){
- jitsu.log.info('Which ' + 'app'.magenta + ' do you want to view?');
+ jitsu.log.info('Which ' + 'app'.magenta + ' to view?');
jitsu.prompt.get(["app name"], function (err, result) {
if (err) {
jitsu.log.error('Prompt error:');
@@ -448,7 +448,7 @@ apps.update = function (name, callback) {
var diff = jitsu.common.objectDiff(app, pkg);
if (!diff) {
- jitsu.log.warn('No changes found to your package.json for ' + name.magenta);
+ jitsu.log.warn('No changes found in package.json for ' + name.magenta);
return callback();
}
View
18 lib/jitsu/commands/databases.js
@@ -10,7 +10,7 @@ var jitsu = require('../../jitsu');
var databases = exports;
databases.usage = [
- '`jitsu databases *` commands allow you to work with the database api',
+ 'The `jitsu databases` commands manages databases',
'',
'jitsu databases create <database type> <database name>',
'jitsu databases list',
@@ -107,7 +107,7 @@ databases.create = function (requestedDatabaseType, requestedDatabaseName, callb
if (!database.name || !database.type) {
if (!database.name) {
- jitsu.log.warn('Database name is required');
+ jitsu.log.error('Database name is required');
getProperties.push({
name: 'database name',
default: database.type
@@ -145,9 +145,9 @@ databases.create.usage = [
databases.get = function (databaseName, callback) {
if (!databaseName) {
- jitsu.log.warn('You need to pass a database name');
+ jitsu.log.warn('Database name required');
jitsu.log.warn('jitsu databases get <database name>');
- jitsu.log.warn('If you want to get a list of all the databases run:');
+ jitsu.log.warn('To list all the databases run:');
jitsu.log.warn('jitsu databases list');
return callback();
}
@@ -187,7 +187,7 @@ databases.list = function (callback) {
});
if (results.length === 0) {
- jitsu.log.info('You have no databases.');
+ jitsu.log.info('No databases found');
}
}
callback();
@@ -202,18 +202,18 @@ databases.list.usage = [
databases.destroy = function (databaseName, callback) {
if (!databaseName) {
- jitsu.log.error('You need to pass a database name');
+ jitsu.log.warn('Database name is required');
jitsu.log.error('jitsu databases destroy <database name>');
return callback();
}
jitsu.databases.destroy(databaseName, function (err) {
if (err) {
- jitsu.log.error('Database could not be destroyed.');
+ jitsu.log.error('Database could not be destroyed');
jitsu.log.error(require('util').inspect(err.result.error));
}
else {
- jitsu.log.info('Database was deleted.');
+ jitsu.log.info('Database was deleted');
}
callback();
});
@@ -285,7 +285,7 @@ var printDbHelp = function (database) {
'',
' $ curl ' + connUrl,
'',
- 'Connect with the `' + 'futon'.magenta + '` web app (' + 'open in your browser'.cyan + '):',
+ 'Connect with the `' + 'futon'.magenta + '` web app (' + 'open in a web browser'.cyan + '):',
'',
' ' + connUrl + '/_utils',
'',
View
6 lib/jitsu/commands/env.js
@@ -10,8 +10,8 @@ var jitsu = require('../../jitsu');
var env = exports;
env.usage = [
- '`jitsu env *` commands allow you to set local environment',
- 'variables for your application. Valid commands are:',
+ '`jitsu env *` commands enable management of environment',
+ 'variables for the app. Valid commands are:',
'',
'jitsu env list',
'jitsu env list <app>',
@@ -34,7 +34,7 @@ env.set = function (appName, key, value, callback) {
if (value === null) {
if (key === null) {
jitsu.log.error(
- 'You must specify both an environment variable name and value.'
+ 'Environment variable name and value and both required'
);
return callback({});
}
View
11 lib/jitsu/commands/install.js
@@ -134,8 +134,7 @@ module.exports = function (requestedApp, callback) {
function promptforAppName(cb) {
jitsu.log.help('The ' + 'install'.magenta + ' command downloads pre-built node apps');
- jitsu.log.help('To continue, you will need to select an app');
- jitsu.log.info('Please choose a node app so we can get you started');
+ jitsu.log.info('Please select a node app to get started');
jitsu.log.info('Available node apps:');
Object.keys(nodeapps).forEach(function (starter) {
jitsu.log.info(starter.magenta + ' ' + nodeapps[starter].description);
@@ -179,7 +178,7 @@ module.exports = function (requestedApp, callback) {
jitsu.log.info('Attempting to configure app based on ' + './config/schema.json'.grey )
jitsu.log.help('Prompting for ' + app.name.magenta + ' configuration data');
- jitsu.log.help('You can hit ' + '[ENTER]'.grey + ' to specify default values');
+ jitsu.log.help('Press ' + '[ENTER]'.grey + ' to specify default values');
wizard.cli.run(schema, function (err, config) {
@@ -239,14 +238,14 @@ module.exports = function (requestedApp, callback) {
}
function deployApp(cb) {
- jitsu.log.info('Jitsu will now help you create your package.json');
+ jitsu.log.info('Jitsu will now help create a package.json');
return jitsu.package.create(process.cwd(), function (err, result) {
if (err) {
return cb(err);
}
- jitsu.log.info('Your app has been created successfully. Deploying!');
- jitsu.log.info('You can run additional deployments using `jitsu deploy`');
+ jitsu.log.info('The app has been created successfully. Deploying!');
+ jitsu.log.info('Run additional deployments using `jitsu deploy`');
return jitsu.plugins.cli.executeCommand(['deploy'],callback);
});
}
View
6 lib/jitsu/commands/logs.js
@@ -10,8 +10,8 @@ var dateformat = require('dateformat');
var logs = exports;
logs.usage = [
- 'The `jitsu logs` commands allow you to read the logs related to your app.',
- 'The default number of lines to show is 10.',
+ 'The `jitsu logs` command will display logs related to the app',
+ 'The default number of lines to show is 10',
'',
'Example usages:',
'jitsu logs all',
@@ -108,7 +108,7 @@ logs.app = function (appName, amount, callback) {
getAppName(function (err, name) {
if (err) {
jitsu.commands.list(function(){
- jitsu.log.info('Which application do you want to view ' + 'logs'.magenta + ' for?');
+ jitsu.log.info('Which application to view ' + 'logs'.magenta + ' for?');
jitsu.prompt.get(["app name"], function (err, result) {
if (err) {
jitsu.log.error('Prompt error:');
View
4 lib/jitsu/commands/package.js
@@ -10,8 +10,8 @@ var jitsu = require('../../jitsu');
var package = exports;
package.usage = [
- '`jitsu package *` commands allow you to work with the tarballs',
- 'that are automatically created by jitsu',
+ 'The `jitsu package` command manages the tarballs',
+ 'which are automatically created by jitsu',
'Valid commands are: ',
'',
'jitsu package create',
View
8 lib/jitsu/commands/snapshots.js
@@ -13,9 +13,9 @@ var fs = require('fs'),
var snapshots = exports;
snapshots.usage = [
- '`jitsu snapshots *` commands allow you to work with snapshots',
- 'for your Applications on Nodejitsu. Snapshots are images of your',
- 'Application\'s code that are deployed to the Nodejitsu Platform.',
+ 'The `jitsu snapshots` command manages snapshots',
+ 'for apps on Nodejitsu. Snapshots are images of the',
+ 'apps\'s code that is deployed to the Nodejitsu Platform.',
'Valid commands are: ',
'',
'jitsu snapshots create',
@@ -98,7 +98,7 @@ snapshots.list = function (name, callback) {
if (err) {
jitsu.log.warn('App name is required to list snapshots')
jitsu.commands.list(function(){
- jitsu.log.info('Which app do you want to view ' + 'snapshots'.magenta + ' for?');
+ jitsu.log.info('Which app to view ' + 'snapshots'.magenta + ' for?');
jitsu.prompt.get(["app name"], function (err, result) {
if (err) {
jitsu.log.error('Prompt error:');
View
14 lib/jitsu/commands/users.js
@@ -57,7 +57,7 @@ users.confirm = function (username, inviteCode, callback) {
if (err) {
if (tries >= 3) {
jitsu.log.error('Three failed login attempts');
- jitsu.log.info('Would you like to reset your password?');
+ jitsu.log.info('Reset the password?');
return offerReset(username);
}
return setupAuth();
@@ -94,9 +94,9 @@ users.confirm = function (username, inviteCode, callback) {
if (!response.hasPassword) {
(function getNewPass() {
- jitsu.log.help('Now that your account is confirmed, you will need to set a password.');
- jitsu.log.help('In the future, you can also reset your password by running the' + ' jitsu users forgot'.magenta + ' command');
- jitsu.log.help('Set your new password below');
+ jitsu.log.help('Now that the account is confirmed, a password is required');
+ jitsu.log.help('In the future, the password can be reset by running the' + ' jitsu users forgot'.magenta + ' command');
+ jitsu.log.help('Set the new password below');
jitsu.prompt.get(['set password', 'confirm password'], function (err, results) {
if (err) {
@@ -124,7 +124,7 @@ users.confirm = function (username, inviteCode, callback) {
}
else {
jitsu.log.info('User ' + username.magenta + ' confirmed');
- jitsu.log.info('Would you like to log in now?');
+ jitsu.log.info('Log in now?');
jitsu.prompt.get(['login'], function (err, result) {
if (err) {
return callback(err);
@@ -158,8 +158,8 @@ users.confirm = function (username, inviteCode, callback) {
// Usage for `jitsu users confirm`.
//
users.confirm.usage = [
- 'Confirms the Nodejitsu user account for the specified username.',
- 'You will be prompted to supply a valid invite code for the account.',
+ 'Confirms a Nodejitsu user account',
+ 'Will prompt for a valid invite code for the account',
'',
'jitsu users confirm <username> <invitecode>'
];
View
4 lib/jitsu/common/index.js
@@ -182,9 +182,9 @@ common.checkVersion = function (callback) {
var pkg = JSON.parse(body);
if (semver.gt(pkg.version, jitsu.version)) {
- jitsu.log.warn('A newer version of ' + 'jitsu'.magenta + ' is available. ' + 'You should update immediately.');
+ jitsu.log.warn('A newer version of ' + 'jitsu'.magenta + ' is available. ' + 'please update immediately');
jitsu.log.help('To install the latest ' + 'jitsu'.magenta + ' type `[sudo] npm install jitsu -g`');
- jitsu.log.warn('If you wish to ' + 'continue'.bold + ' without an update you must ' + 'type'.cyan + ' ' + '\'yes\''.magenta);
+ jitsu.log.warn('To ' + 'continue'.bold + ' without an update ' + 'type'.cyan + ' ' + '\'yes\''.magenta);
jitsu.prompt.get({
message: 'Continue without updating? Bad things might happen (no)',
View
8 lib/jitsu/config.js
@@ -40,8 +40,8 @@ catch (err) {
console.log('Error parsing ' + jitsu.config.stores.file.file.magenta);
console.log(err.message);
console.log('');
- console.log('This is most likely not an error in jitsu.');
- console.log('Please check your jitsuconf and try again.');
+ console.log('This is most likely not an error in jitsu');
+ console.log('Please check the .jitsuconf file and try again');
console.log('');
process.exit(1);
}
@@ -99,8 +99,8 @@ jitsu.use(require('flatiron-cli-config'), {
configFile = jitsu.config.stores.file.file;
var display = [
- ' here is your ' + configFile.grey + ' file:',
- 'If you\'d like to change a property try:',
+ ' here is the ' + configFile.grey + ' file:',
+ 'To change a property type:',
'jitsu config set <key> <value>',
];
View
20 lib/jitsu/package.js
@@ -109,8 +109,8 @@ package.tryRead = function (dir, callback, success) {
package.create = function (dir, callback) {
var help = [
'',
- 'A package.json stores meta-data about your application',
- 'In order to continue we\'ll need to gather some information about your app',
+ 'A package.json stores meta-data about an app',
+ 'In order to continue we\'ll need to gather some information about the app',
'',
'Press ^C at any time to quit.',
'to select a default value, press ENTER'
@@ -219,7 +219,7 @@ package.validate = function (pkg, dir, options, callback) {
if (missingNames.length) {
help = help.concat([
- 'Your package.json file is missing required fields:',
+ 'The package.json file is missing required fields:',
'',
missingNames.join(', '),
''
@@ -228,7 +228,7 @@ package.validate = function (pkg, dir, options, callback) {
if (invalidNames.length) {
help = help.concat([
- 'Your package.json file has invalid required fields:',
+ 'The package.json file has invalid required fields:',
'',
invalidNames.join(', '),
''
@@ -308,7 +308,7 @@ package.write = function (pkg, dir, create, callback) {
// Analyzes the dependencies in `pkg` using the `require-analyzer` module.
//
package.analyzeDependencies = function (pkg, dir, callback) {
- jitsu.log.info('Analyzing your application dependencies in ' + pkg.scripts.start.magenta);
+ jitsu.log.info('Analyzing application dependencies in ' + pkg.scripts.start.magenta);
analyzer.analyze({ target: path.join(dir, pkg.scripts.start) }, function (err, pkgs) {
//
// Create a hash of `'package': '>= version'` for the new dependencies
@@ -410,7 +410,7 @@ package.updateTarball = function (version, pkg, existing, firstSnapshot, callbac
// XXX Is 50mb enough? Please warning message
if (stat.size > 50 * 1024 * 1024) {
- jitsu.log.warn('You\'re trying to upload snapshot larger than ' + '50M'.magenta + '.');
+ jitsu.log.warn('Snapshot is larger than ' + '50M'.magenta + '!');
jitsu.log.warn('This is not recommended practice.');
}
@@ -508,8 +508,8 @@ package.properties = function (dir) {
validator: /[\w|\-|\_]+/,
help: [
'',
- 'The ' + 'subdomain '.grey + 'is where your application will reside.',
- 'Your application will then become accessible at: http://' + 'yourdomain'.grey + '.jit.su',
+ 'The ' + 'subdomain '.grey + 'is where the app will reside',
+ 'The app will then become accessible at: http://' + 'subdomain'.grey + '.jit.su',
''
],
default: jitsu.config.get('username') + '.' + path.basename(dir)
@@ -594,10 +594,10 @@ package.available = function (pkg, dir, callback, createPackage) {
}
if (fields.indexOf('name') !== -1) {
- jitsu.log.error('The application name you have requested is already in use.');
+ jitsu.log.error('The app name requested is already in use');
}
if (fields.indexOf('subdomain') !== -1) {
- jitsu.log.error('The subdomain you have requested is already in use.');
+ jitsu.log.error('The subdomain requested is already in use');
}
jitsu.prompt.addProperties(pkg, props, createPackage);
return;
View
8 lib/jitsu/properties.js
@@ -14,12 +14,12 @@ module.exports = {
},
askstarter: {
name: 'askstarter',
- message: 'Would you like to use a node app? (recommended)',
+ message: 'Use a node app? (recommended)',
default: 'yes'
},
appname: {
name: 'appname',
- message: 'Please enter the name you would like to use for your app',
+ message: 'Name of the app',
default: 'myapp'
},
snapshot: {
@@ -33,7 +33,7 @@ module.exports = {
},
starter: {
name: 'starter',
- message: 'Which node app would you like to install?',
+ message: 'Which node app to install?',
default: 'helloworld'
},
proceed: {
@@ -51,7 +51,7 @@ module.exports = {
},
"start_local": {
name: 'start_local',
- message: 'Would you like to start this application locally?',
+ message: 'Start this application locally?',
validator: /y[es]?|n[o]?/,
warning: 'Must respond yes or no',
default: 'yes'
View
2  test/commands/users-test.js
@@ -55,7 +55,7 @@ vows.describe('jitsu/commands/users').addBatch({
nock('http://api.mockjitsu.com')
.post('/users/elvis/confirm', { username: 'elvis', 'inviteCode': 'f4387f4' })
.reply(200, {
- message: 'Your ninja status has been confirmed!',
+ message: 'Ninja status has been confirmed!',
hasPassword: true
}, { 'x-powered-by': 'Nodejitsu' });
})
Please sign in to comment.
Something went wrong with that request. Please try again.