Comparing version 0.0.8 to 0.0.10
{ | ||
"name": "worksmith", | ||
"version": "0.0.8", | ||
"version": "0.0.10", | ||
"description": "A purely functional workflow engine ", | ||
@@ -25,7 +25,9 @@ "main": "index.js", | ||
"dependencies": { | ||
"async": "^0.9.0", | ||
"debug": "^2.1.3", | ||
"handlebars": "^3.0.2", | ||
"lodash": "^3.7.0", | ||
"pg": "^4.3.0", | ||
"xregexp": "^2.0.0" | ||
} | ||
} |
@@ -1,2 +0,2 @@ | ||
# WorkSmith | ||
# worksmith | ||
@@ -9,9 +9,9 @@ ```npm i worksmith --save``` | ||
## Highlights | ||
- WorkSmith comes with an extensible task library | ||
- worksmith comes with an extensible task library | ||
- Control flow: ```sequence``` , ```parallel``` and ```warezSequence``` | ||
- IO: ```log```,```sql/pg``` | ||
- Tansformation: ```map```, ```regex```, ```set``` | ||
- Extensibitly: ```code``` task type, create custom task types by creating files in the tasks folder | ||
- Extensibitly: ```code``` activity , create custom task types by creating files in the tasks folder | ||
- with WorkSmith you can build a complex async process chain from functional steps (tasks) - yet keep the application easy to understand and each functional step easy to developer and maintain. forget ```if(err) return next(err)``` | ||
- with worksmith you can build a complex async process chain from functional steps (tasks) - yet keep the application easy to understand and each functional step easy to developer and maintain. forget ```if(err) return next(err)``` | ||
- workflow steps are unaware about each other - they communicate over a shared context. WorkSmith provides an intuitive expression syntax for working with the context in a workflow definitions | ||
@@ -21,2 +21,3 @@ ## usage | ||
### A workflow definition: | ||
This can be in a config file, or as part of your js code as a variable. | ||
@@ -69,3 +70,3 @@ ```javascript | ||
WorkSmith lets you build your activities on a super easy way | ||
worksmith lets you build your activities on a super easy way | ||
Place the following code as ```"hello-world.js"``` in the ```tasks``` folder | ||
@@ -72,0 +73,0 @@ |
@@ -1,5 +0,2 @@ | ||
var debug = require('debug')('workflow:activities:sql:pg') | ||
var pg = require('pg') | ||
var _ = require('lodash') | ||
var workflow = require('../') | ||
var debug = require('debug')('workflow:activities:code') | ||
@@ -6,0 +3,0 @@ |
@@ -5,2 +5,3 @@ var debug = require('debug')('workflow:activities:map') | ||
//TODO: refactor and place this to wf creator level | ||
Object.keys(definition).forEach(function(key) { | ||
@@ -7,0 +8,0 @@ if (key[0] === ">") { |
@@ -6,2 +6,12 @@ var debug = require('debug')('workflow:activities:log') | ||
module.exports = function (node) { | ||
//TODO: refactor and place this to wf creator level | ||
Object.keys(node).forEach(function (key) { | ||
if (key[0] === ">") { | ||
node.value = node[key]; | ||
node.resultTo = key.slice(1); | ||
delete node[key] | ||
} | ||
}); | ||
//for performance considerations the regex pattern should be constructed w/o using context variables | ||
var p = XRegExp(node.pattern,'x'); | ||
@@ -8,0 +18,0 @@ |
39071
32
869
145
6
+ Addedasync@^0.9.0
+ Addedpg@^4.3.0
+ Addedasync@0.9.2(transitive)
+ Addedbuffer-writer@1.0.1(transitive)
+ Addedgeneric-pool@2.4.2(transitive)
+ Addedjs-string-escape@1.0.1(transitive)
+ Addedpacket-reader@0.2.0(transitive)
+ Addedpg@4.5.7(transitive)
+ Addedpg-connection-string@0.1.3(transitive)
+ Addedpg-int8@1.0.1(transitive)
+ Addedpg-types@1.13.0(transitive)
+ Addedpgpass@0.0.3(transitive)
+ Addedpostgres-array@1.0.3(transitive)
+ Addedpostgres-bytea@1.0.0(transitive)
+ Addedpostgres-date@1.0.7(transitive)
+ Addedpostgres-interval@1.2.0(transitive)
+ Addedsemver@4.3.6(transitive)
+ Addedsplit@0.3.3(transitive)
+ Addedthrough@2.3.8(transitive)
+ Addedxtend@4.0.2(transitive)