New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

gulp-livescript

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gulp-livescript - npm Package Compare versions

Comparing version 2.0.0 to 2.1.0

8

CHANGELOG.md

@@ -0,1 +1,9 @@

## 2.1.0 (2014-11-06)
#### Features
* **index.js:** add support for .json.ls extension ([043d92da](https://github.com/tomchentw/gulp-livescript/commit/043d92da728fa90adb29909557db3c4cd69802a8))
## 2.0.0 (2014-10-17)

@@ -2,0 +10,0 @@

20

lib/index.js

@@ -1,4 +0,5 @@

var through2, LiveScript, gutil;
var through2, LiveScript, path, gutil;
through2 = require('through2');
LiveScript = require('LiveScript');
path = require('path');
gutil = require('gulp-util');

@@ -8,3 +9,3 @@ module.exports = function(options){

function modifyLS(file, enc, done){
var error, fileExtension, input, t, json;
var error, input, dirname, filename, json, t;
if (file.isNull()) {

@@ -17,4 +18,12 @@ return done(null, file);

try {
fileExtension = ".js";
input = file.contents.toString("utf8");
dirname = path.dirname(file.path);
filename = path.basename(file.path, '.ls');
if (path.extname(filename) === '.json' || options.json) {
file.path = path.join(dirname, path.basename(file.path, '.json') + '.json');
json = true;
} else {
file.path = path.join(dirname, filename + '.js');
json = false;
}
t = {

@@ -24,3 +33,2 @@ input: input,

};
json = options.json;
t.tokens = LiveScript.tokens(t.input, {

@@ -37,7 +45,5 @@ raw: options.lex

t.result = LiveScript.run(t.output, options, true);
t.output = JSON.stringify(t.result, null, 2) + "\n";
fileExtension = ".json";
t.output = JSON.stringify(t.result, null, 2) + '\n';
}
file.contents = new Buffer(t.output);
file.path = gutil.replaceExtension(file.path, fileExtension);
} catch (e$) {

@@ -44,0 +50,0 @@ error = e$;

{
"name": "gulp-livescript",
"version": "2.0.0",
"version": "2.1.0",
"description": "Compile LiveScript to JavaScript for Gulp",

@@ -5,0 +5,0 @@ "main": "lib/index.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