forked from imgag/megSAP
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
96 lines (75 loc) · 3.12 KB
/
Makefile
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
help:
@echo "Main targets:"
@echo " test_functions - perform function tests."
@echo " test_tools - perform tool tests."
@echo " test_tools_db - perform DB tool tests."
@echo " test_pipeline_a - perform DNA amplicon pipeline test."
@echo " test_pipeline_x - perform DNA shotgun pipeline test."
@echo " test_pipeline_t - perform DNA trio pipeline test."
@echo " test_pipeline_m - perform DNA multi-sample pipeline test."
@echo " test_pipeline_s - perform DNA somatic pipeline test."
@echo " test_pipeline_r - perform RNA pipeline test."
@echo " test_all - perform all tests in parallel (functions, tools, pipelines)."
@echo " test_all_status - shows the output summary of 'test_all'."
@echo ""
@echo "Auxilary targets:"
@echo " find_missing_tests - Checks for tools that do not have a test."
@echo " todos - Checks for todos in the code"
@echo " pull - Pull latest version from GitHub"
pull:
git pull --recurse-submodules
git describe --tags > megSAP_tag.txt
git status
test_functions: dummy
@cd test && find . -name "test_*.php" | sort | xargs -l1 php | egrep "^(FINISHED|FAILED)"
test_tools: dummy
@cd test && find . -name "tool_test_*.php" | sort | xargs -l1 php | egrep "^(FINISHED|FAILED)"
test_tools_primer: dummy
@cd test && find . -name "tool_test_*.php" | xargs grep -l "/Primer/" | sort | xargs -l1 php | egrep "^(FINISHED|FAILED)"
test_tools_ngs: dummy
@cd test && find . -name "tool_test_*.php" | xargs grep -l "/NGS/" | sort | xargs -l1 php | egrep "^(FINISHED|FAILED)"
test_tools_tools: dummy
@cd test && find . -name "tool_test_*.php" | xargs grep -l "/Tools/" | sort | xargs -l1 php | egrep "^(FINISHED|FAILED)"
test_tools_db:
@cd test && find . -name "tool_test_db*.php" | sort | xargs -l1 php | egrep "^(FINISHED|FAILED)"
test_pipeline_a: dummy
@cd test/data_amplicon && make all
test_pipeline_x: dummy
@cd test/data_chrx && make all
test_pipeline_s: dummy
@cd test/data_somatic && make all
test_pipeline_t: dummy
@cd test/data_trio && make all
test_pipeline_m: dummy
@cd test/data_multi && make all
test_pipeline_r: dummy
@cd test/data_rna && make all
test_all: dummy
(cd test && find . -name "test_*.php" | sort | xargs -l1 php && echo "DONE") > f.log 2>&1 &
(cd test && find . -name "tool_test_*.php" | sort | xargs -l1 php && echo "DONE") > t.log 2>&1 &
make test_pipeline_a > p_a.log 2>&1 &
make test_pipeline_x > p_x.log 2>&1 &
make test_pipeline_s > p_s.log 2>&1 &
make test_pipeline_t > p_t.log 2>&1 &
make test_pipeline_m > p_m.log 2>&1 &
make test_pipeline_r > p_r.log 2>&1 &
test_all_status:
@clear
@tail -v -n3 *.log
@echo ""
@echo "### WARNINGS ###"
@egrep -a -i "WARNING" *.log || :
@echo ""
@echo "### ERRORS ###"
@egrep -a -i "ERROR|FAILED" *.log | grep -v "Medelian errors:" || :
find_missing_tests: dummy
php src/Tools/find_missing_tests.php
find_unused_tools: dummy
php src/Tools/find_unused_tools.php -ngsbits ../ngs-bits/ -megsap .
todos:
find . -name "*.php" | xargs grep -i "@todo"
swap_settings:
mv settings.ini settings.ini.swap
mv settings_nightly.ini settings.ini
mv settings.ini.swap settings_nightly.ini
dummy: