Socket
Socket
Sign inDemoInstall

gulp-inject

Package Overview
Dependencies
Maintainers
1
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gulp-inject - npm Package Compare versions

Comparing version 4.3.0 to 4.3.1

commitlint.config.js

19

package.json
{
"name": "gulp-inject",
"version": "4.3.0",
"version": "4.3.1",
"description": "A javascript, stylesheet and webcomponent injection plugin for Gulp, i.e. inject file references into your index.html",

@@ -29,10 +29,13 @@ "keywords": [

"test": "mocha -R spec src/**/*_test.js",
"semantic-release": "semantic-release pre && npm publish && semantic-release post"
"semantic-release": "semantic-release",
"commitmsg": "commitlint -e"
},
"dependencies": {
"ansi-colors": "^1.0.1",
"arrify": "^1.0.1",
"escape-string-regexp": "^1.0.5",
"event-stream": "^3.1.0",
"fancy-log": "^1.3.2",
"group-array": "^0.3.0",
"gulp-util": "^3.0.0",
"plugin-error": "^0.1.2",
"stream-to-array": "^2.3.0",

@@ -42,7 +45,11 @@ "through2": "^2.0.1"

"devDependencies": {
"@commitlint/cli": "^3.2.0",
"@commitlint/config-angular": "^3.1.1",
"husky": "^0.14.3",
"mocha": "~2.0.1",
"semantic-release": "^12.4.1",
"should": "^4.0.4",
"strip-color": "^0.1.0",
"xo": "^0.13.0",
"semantic-release": "^7.0.2"
"vinyl": "^2.1.0",
"xo": "^0.13.0"
},

@@ -65,2 +72,2 @@ "engines": {

}
}
}
# gulp-inject
---
## HELP WANTED
### Contributors are welcomed!
**I don't have enough time to maintain this plugin as I would want to, so I'm looking for people who want to help out and be contributors/repository admins.**
#### Interested?
**Contact me! See `package.json` for contact information.**
---
[![NPM version][npm-image]][npm-url] [![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release) [![Build Status][travis-image]][travis-url] [![XO code style][codestyle-image]][codestyle-url] [![Dependency Status][depstat-image]][depstat-url]

@@ -857,2 +871,10 @@

#### options.quiet
Type: `Boolean`
Default: `false`
Lower the verbosity by setting this to true, suppressing the logging of successful injections.
#### ~~options.templateString~~

@@ -859,0 +881,0 @@

'use strict';
var through2 = require('through2');
var gutil = require('gulp-util');
var fancyLog = require('fancy-log');
var PluginError = require('plugin-error');
var colors = require('ansi-colors');
var streamToArray = require('stream-to-array');

@@ -12,5 +14,4 @@ var escapeStringRegexp = require('escape-string-regexp');

var PluginError = gutil.PluginError;
var magenta = gutil.colors.magenta;
var cyan = gutil.colors.cyan;
var magenta = colors.magenta;
var cyan = colors.cyan;
var noop = function noop() {};

@@ -288,3 +289,3 @@

function log(message) {
gutil.log(magenta(PLUGIN_NAME), message);
fancyLog.info(magenta(PLUGIN_NAME), message);
}

@@ -291,0 +292,0 @@

/* eslint-env mocha */
'use strict';
var path = require('path');
var File = require('gulp-util').File;
var Vinyl = require('vinyl');
require('should');

@@ -11,3 +11,3 @@ var getFilepath = require('./');

it('returns the path relative to the source file\'s cwd', function () {
var source = new File({
var source = new Vinyl({
cwd: __dirname,

@@ -23,3 +23,3 @@ path: path.join(__dirname, 'dir', 'file.js'),

it('returns the unixified path relative to the source file\'s cwd', function () {
var source = new File({
var source = new Vinyl({
cwd: 'C:\\a\\folder',

@@ -37,3 +37,3 @@ path: 'C:\\a\\folder\\dir\\file.js',

it('returns the path relative to the target file\'s directory', function () {
var target = new File({
var target = new Vinyl({
cwd: __dirname,

@@ -43,3 +43,3 @@ path: path.join(__dirname, 'dir1', 'index.html'),

});
var source = new File({
var source = new Vinyl({
cwd: __dirname,

@@ -55,3 +55,3 @@ path: path.join(__dirname, 'dir2', 'file.js'),

it('returns the unixified path relative to the source file\'s cwd', function () {
var target = new File({
var target = new Vinyl({
cwd: 'C:\\a\\folder',

@@ -61,3 +61,3 @@ path: 'C:\\a\\folder\\dir1\\index.html',

});
var source = new File({
var source = new Vinyl({
cwd: 'C:\\a\\folder',

@@ -75,3 +75,3 @@ path: 'C:\\a\\folder\\dir2\\file.js',

it('removes the provided `ignorePath` from the beginning of the path', function () {
var source = new File({
var source = new Vinyl({
cwd: __dirname,

@@ -87,3 +87,3 @@ path: path.join(__dirname, 'dir', 'file.js'),

it('removes the provided `ignorePath` even if it both begins and ends in a `/` from the beginning of the path', function () {
var source = new File({
var source = new Vinyl({
cwd: __dirname,

@@ -99,3 +99,3 @@ path: path.join(__dirname, 'dir', 'file.js'),

it('removes the provided `ignorePath`s from the beginning of the path', function () {
var source = new File({
var source = new Vinyl({
cwd: __dirname,

@@ -111,3 +111,3 @@ path: path.join(__dirname, 'dir', 'file.js'),

it('removes the provided `ignorePath` unixified from the beginning of the path', function () {
var source = new File({
var source = new Vinyl({
cwd: __dirname,

@@ -123,3 +123,3 @@ path: path.join(__dirname, 'dir', 'deep', 'file.js'),

it('removes the provided `ignorePath` unixified from the beginning of a unixified path', function () {
var source = new File({
var source = new Vinyl({
cwd: 'C:\\a\\folder',

@@ -135,3 +135,3 @@ path: 'C:\\a\\folder\\dir\\deep\\file.js',

it('removes the provided `ignorePath` from the beginning of a unixified path', function () {
var source = new File({
var source = new Vinyl({
cwd: 'C:\\a\\folder',

@@ -149,3 +149,3 @@ path: 'C:\\a\\folder\\dir\\deep\\file.js',

it('prepends the path with a `/`', function () {
var source = new File({
var source = new Vinyl({
cwd: __dirname,

@@ -163,3 +163,3 @@ path: path.join(__dirname, 'dir', 'file.js'),

it('prepends the prefix and a `/` to the path', function () {
var source = new File({
var source = new Vinyl({
cwd: __dirname,

@@ -175,3 +175,3 @@ path: path.join(__dirname, 'dir', 'file.js'),

it('keeps any leading `/` from the prefix', function () {
var source = new File({
var source = new Vinyl({
cwd: __dirname,

@@ -189,3 +189,3 @@ path: path.join(__dirname, 'dir', 'file.js'),

it('appends the suffix to the path', function () {
var source = new File({
var source = new Vinyl({
cwd: __dirname,

@@ -192,0 +192,0 @@ path: path.join(__dirname, 'dir', 'file.js'),

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