forked from tech-srl/code2vec
- Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathextractPaths.sh
More file actions
Latest commit
26 lines (21 loc) · 542 Bytes
/
Copy pathextractPaths.sh
File metadata and controls
26 lines (21 loc) · 542 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/bash
# database -- dataset -- target file name -- number of cores
PHARO_VM=PharoExtractor/pharo
TMP_NAME=`date +%s`
mkdir -p tmp/$TMP_NAME
FAIL=0
foriin`seq 1 $4`;do
TMP_PATH[${i}]="tmp/${TMP_NAME}/${i}.tmp"
$PHARO_VM --headless PharoExtractor/work.image extractFromDB $1$2$4$i>${TMP_PATH[${i}]}&
pids[${i}]=$!
done
# wait for all pids
forpidin${pids[*]};do
wait$pid||echo"Error on process $pid"
done
rm -f $3
touch $3
fortmp_filein${TMP_PATH[*]};do
cat $tmp_file>>$3
done
rm -r tmp/$TMP_NAME