aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/PursLoader/Glob.js
diff options
context:
space:
mode:
authoreric thul <thul.eric@gmail.com>2015-08-11 20:57:07 -0400
committereric thul <thul.eric@gmail.com>2015-08-11 20:57:07 -0400
commit03b840cb5fb8ff5217fefc9e1240a3131db309fc (patch)
tree6183f4453aa15ad67ee0249fb8d35702cef5ecad /src/PursLoader/Glob.js
parentfa01c5a4cb42d80ac147dc5ab512a0795dbe14da (diff)
downloadpurs-loader-03b840cb5fb8ff5217fefc9e1240a3131db309fc.tar.gz
purs-loader-03b840cb5fb8ff5217fefc9e1240a3131db309fc.tar.zst
purs-loader-03b840cb5fb8ff5217fefc9e1240a3131db309fc.zip
PureScript 0.7 updates and migration to pulp
Diffstat (limited to 'src/PursLoader/Glob.js')
-rw-r--r--src/PursLoader/Glob.js18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/PursLoader/Glob.js b/src/PursLoader/Glob.js
new file mode 100644
index 0000000..960ae9a
--- /dev/null
+++ b/src/PursLoader/Glob.js
@@ -0,0 +1,18 @@
1'use strict';
2
3// module PursLoader.Glob
4
5var glob = require('glob');
6
7var async = require('async');
8
9function globAllFn(patterns, errback, callback) {
10 return function(){
11 async.map(patterns, glob, function(error, result){
12 if (error) errback(new Error(error))();
13 else callback(result)();
14 });
15 };
16}
17
18exports.globAllFn = globAllFn;