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

main-bower-files

Package Overview
Dependencies
Maintainers
2
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

main-bower-files - npm Package Compare versions

Comparing version 2.8.0 to 2.8.1

0

index.js
module.exports = process.env.LIB_COV ? require('./lib-cov') : require('./lib');

4

lib/index.js
var fs = require('fs'),
exists = require('path-exists').sync,
path = require('path'),
globule = require('globule'),
multimatch = require('multimatch'),
PackageCollection = require('./package_collection');

@@ -98,3 +98,3 @@

if (typeof opts.filter === 'string' || Array.isArray(opts.filter)) {
files = globule.match(opts.filter, files);
files = multimatch(files, opts.filter);
} else if (opts.filter instanceof RegExp) {

@@ -101,0 +101,0 @@ files = files.filter(function(file) {

@@ -0,0 +0,0 @@ require('colors');

var path = require('path'),
fs = require('fs'),
exists = require('path-exists').sync,
stripJsonComments = require('strip-json-comments'),
_ = require('lodash'),
extend = require('extend'),
Package = require('./package'),

@@ -66,3 +67,3 @@ logger = require('./logger'),

collectPackages: function() {
if (!fs.existsSync(this.opts.paths.bowerJson)) {
if (!exists(this.opts.paths.bowerJson)) {
throw new Error('bower.json does not exist at: ' + this.opts.paths.bowerJson);

@@ -85,3 +86,3 @@ }

this.overrides = _.defaults(bowerJson.overrides || {}, this.overrides);
this.overrides = extend(bowerJson.overrides || {}, this.overrides);

@@ -88,0 +89,0 @@ if (includeDev !== 'exclusive') {

var path = require('path'),
fs = require('fs'),
exists = require('path-exists').sync,
glob = require('glob'),
globby = require('globby').sync,
logger = require('./logger'),

@@ -140,3 +140,3 @@ Package;

main.forEach(function(pattern) {
var _files = glob.sync(pattern, {
var _files = globby(pattern, {
cwd: this.path

@@ -143,0 +143,0 @@ });

{
"name": "main-bower-files",
"version": "2.8.0",
"version": "2.8.1",
"description": "Get main files from your installed bower packages.",

@@ -27,6 +27,5 @@ "main": "index.js",

"colors": "^0.6.2",
"glob": "^4.0.3",
"globule": "^0.2.0",
"lodash": "^3.8.0",
"minimatch": "^1.0.0",
"extend": "^2.0.1",
"globby": "^2.0.0",
"multimatch": "^2.0.0",
"path-exists": "^1.0.0",

@@ -33,0 +32,0 @@ "strip-json-comments": "^1.0.2",

@@ -134,3 +134,3 @@ main-bower-files

"development": "file.js",
"production": "file.min.js",
"production": "file.min.js"
}

@@ -137,0 +137,0 @@ }

@@ -0,0 +0,0 @@ 'use strict';

@@ -0,0 +0,0 @@ {

@@ -0,0 +0,0 @@ {

@@ -0,0 +0,0 @@ {

@@ -0,0 +0,0 @@ {

{
"main": "main.js"
}

@@ -0,0 +0,0 @@ {

@@ -0,0 +0,0 @@ {

{
"main": "./decoy.js"
}
// I do nothing and should not be listed.
{
"main": "lib/deeppaths.js"
}
{
"main": "default.js"
}
// I do nothing and should not be on the list, because I was ignored by the bower.json
{
"main": "./includeDev.js"
}
{
"main": "not-existing-file.js"
}
{
"name": "not-existing-main"
}
// I do nothing, but I am on the list!
{
"main": "./overwritten.js"
}
// I do nothing and should not be on the list, because I was overwritten by the bower.json
{
"main": "./simple.js"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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