|
@@ -0,0 +1,20 @@
|
|
|
|
|
+import { spawn } from 'child_process';
|
|
|
|
|
+import { cpus } from 'os';
|
|
|
|
|
+
|
|
|
|
|
+const async_exec = (prog, args, onData) => {
|
|
|
|
|
+ return new Promise((resolve, reject) => {
|
|
|
|
|
+ const child = spawn(prog, args, {shell: true})
|
|
|
|
|
+
|
|
|
|
|
+ child.stdout.on('data', data => onData(data.toString().trim()))
|
|
|
|
|
+ child.stderr.on('data', data => onData(data.toString().trim()))
|
|
|
|
|
+
|
|
|
|
|
+ child.on('error', err => reject(err))
|
|
|
|
|
+ child.on('exit', code => resolve(code))
|
|
|
|
|
+ })
|
|
|
|
|
+}
|
|
|
|
|
+
|
|
|
|
|
+const alignOn = (R1, R2, ref, bamOut, opt) => {
|
|
|
|
|
+ return R1
|
|
|
|
|
+}
|
|
|
|
|
+
|
|
|
|
|
+module.exports = alignOn
|