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

helpful-cli

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

helpful-cli - npm Package Compare versions

Comparing version 1.0.2 to 1.0.3

2

commands/init/tasks/12_compileDeps.js

@@ -22,3 +22,3 @@ const _ = require('lodash');

if (input.tags.frontend) {
jsDev.push('browser-sync');
jsDev.push('browser-sync@~2.16.0');
}

@@ -25,0 +25,0 @@ }

@@ -20,4 +20,4 @@ const _ = require('lodash');

_gitignore: true,
_env: (input.deps.js.indexOf('dotenv') !== -1),
'_env.example': (input.deps.js.indexOf('dotenv') !== -1),
_env: utils.has(input.deps.jsDev, 'dotenv', true),
'_env.example': utils.has(input.deps.jsDev, 'dotenv', true),
'public/_gitignore': (input.tags.frontend && input.projectType !== 'lib'),

@@ -27,4 +27,4 @@ 'public/images/_gitkeep': (input.tags.frontend && input.projectType !== 'lib'),

'test/mocha.opts': input.tags.javascript,
'bs.config.js': (input.deps.jsDev.indexOf('browser-sync') !== -1),
'rollup.config.js': (input.deps.jsDev.indexOf('rollup') !== -1),
'bs.config.js': utils.has(input.deps.jsDev, 'browser-sync'),
'rollup.config.js': utils.has(inputs.deps.jsDev, 'rollup', true),
Procfile: (input.targetEnv === 'foreman'),

@@ -31,0 +31,0 @@ Dockerfile: (input.targetEnv === 'docker'),

const fs = require('fs-extra');
const path = require('path');
const utils = require('../utils');

@@ -22,7 +23,7 @@ module.exports = function (input, done) {

if (input.deps.js.indexOf('http-server') !== -1) {
if (utils.has(input.deps.js, 'http-server', true)) {
pkg.scripts['start'].push('http-server');
}
if (input.deps.jsDev.indexOf('stylus') !== -1) {
if (utils.has(input.deps.jsDev, 'stylus', true)) {
pkg.scripts['dev:start'].push('npm run watch:styles');

@@ -34,3 +35,3 @@ pkg.scripts['build'].push('npm run build:styles');

if (input.deps.jsDev.indexOf('rollup') !== -1) {
if (utils.has(input.deps.jsDev, 'rollup', true)) {
pkg.scripts['dev:start'].push('npm run watch:scripts');

@@ -56,3 +57,3 @@ pkg.scripts['build'].push('npm run build:scripts');

if (input.deps.jsDev.indexOf('browser-sync') !== -1) {
if (utils.has(input.deps.jsDev, 'browser-sync')) {
pkg.scripts['dev:start'].push('npm run reload');

@@ -59,0 +60,0 @@ pkg.scripts['reload'] = 'browser-sync start --config bs.config.js';

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

const minimatch = require('minimatch');
exports.getTruthyKeys = function (obj) {

@@ -5,2 +7,11 @@ return Object.keys(obj).filter(function (key) {

});
}
exports.has = function (list, tag, strict) {
for (var i = 0; i < list.length; i++) {
if (( ! strict && list[i].includes(tag)) || (strict && minimatch(list[i], tag))) {
return true;
}
}
return false;
}
{
"name": "helpful-cli",
"version": "1.0.2",
"version": "1.0.3",
"description": "Command line utility for the Helpful Human team.",

@@ -36,2 +36,3 @@ "main": "index.js",

"lodash": "^4.16.3",
"minimatch": "^3.0.3",
"nunjucks": "^2.5.2",

@@ -38,0 +39,0 @@ "ramda": "^0.22.1",

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