Compare commits

...

9 Commits

Author SHA1 Message Date
cb805898c9 3.0.4 2016-04-09 22:51:35 +02:00
c09fe29d99 added memory to object function 2016-04-09 22:51:30 +02:00
a787836e56 added toObject function to memory module 2016-04-07 23:38:24 +02:00
287c2fa99f 3.0.3 2016-04-05 01:00:23 +02:00
111b70aefb updated deps 2016-04-05 01:00:23 +02:00
be91e22447 3.0.2 2016-04-05 00:37:15 +02:00
a337663830 now using carets 2016-04-05 00:37:10 +02:00
2cbb14c515 3.0.1 2016-04-05 00:36:23 +02:00
68cc85b684 update deps 2016-04-05 00:36:19 +02:00
3 changed files with 37 additions and 13 deletions

File diff suppressed because one or more lines are too long

View File

@ -1,6 +1,6 @@
{
"name": "smartfile",
"version": "3.0.0",
"version": "3.0.4",
"description": "offers smart ways to work with files in nodejs",
"main": "dist/index.js",
"scripts": {
@ -25,20 +25,20 @@
},
"homepage": "https://github.com/pushrocks/smartfile",
"dependencies": {
"beautylog": "4.1.0",
"fs-extra": "0.26.7",
"beautylog": "^4.1.2",
"fs-extra": "^0.26.7",
"gulp": "^3.9.1",
"gulp-remote-src": "^0.4.1",
"js-yaml": "3.5.5",
"q": "1.4.1",
"request": "^2.69.0",
"js-yaml": "^3.5.5",
"q": "^1.4.1",
"request": "^2.70.0",
"require-reload": "0.2.2",
"vinyl": "1.1.1",
"vinyl-file": "2.0.0"
"vinyl": "^1.1.1",
"vinyl-file": "^2.0.0"
},
"devDependencies": {
"gulp-function": "^1.2.3",
"npmts": "5.0.0",
"gulp-function": "^1.3.1",
"npmts": "^5.0.4",
"should": "^8.3.0"
}
}

View File

@ -1,9 +1,11 @@
/// <reference path="./typings/main.d.ts" />
import plugins = require("./smartfile.plugins");
import SmartfileInterpreter = require("./smartfile.interpreter");
let Readable = require("stream").Readable;
/**
* allows you to create a gulp stream from filestring
* allows you to create a gulp stream
* from String, from an Array of Strings, from Vinyl File, from an Array of VinylFiles
* @param fileArg
* @returns stream.Readable
* @TODO: make it async;
@ -37,6 +39,16 @@ export let toGulpStream = function(fileArg:string|string[]|plugins.vinyl|plugins
return stream;
};
/**
* converts file to Object
* @param fileStringArg
* @param fileTypeArg
* @returns {any|any}
*/
export let toObject = function(fileStringArg:string,fileTypeArg:string){
return SmartfileInterpreter(fileStringArg,fileTypeArg);
};
/**
* takes a string and converts it to vinyl file
* @param fileArg
@ -69,6 +81,7 @@ export let toVinylArraySync = function(arrayArg:string[],optionsArg?:{filename?:
return vinylArray;
};
/**
* takes a vinylFile object and converts it to String
*/