ngs_server 0.1 → 0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (248) hide show
  1. data/bin/ngs_server +72 -50
  2. data/ext/bamtools/extconf.rb +3 -3
  3. data/ext/vcftools/Makefile +28 -0
  4. data/ext/vcftools/README.txt +36 -0
  5. data/ext/vcftools/cpp/.svn/all-wcprops +125 -0
  6. data/ext/vcftools/cpp/.svn/dir-prop-base +6 -0
  7. data/ext/vcftools/cpp/.svn/entries +708 -0
  8. data/ext/vcftools/cpp/.svn/text-base/Makefile.svn-base +46 -0
  9. data/ext/vcftools/cpp/.svn/text-base/dgeev.cpp.svn-base +146 -0
  10. data/ext/vcftools/cpp/.svn/text-base/dgeev.h.svn-base +43 -0
  11. data/ext/vcftools/cpp/.svn/text-base/output_log.cpp.svn-base +79 -0
  12. data/ext/vcftools/cpp/.svn/text-base/output_log.h.svn-base +34 -0
  13. data/ext/vcftools/cpp/.svn/text-base/parameters.cpp.svn-base +535 -0
  14. data/ext/vcftools/cpp/.svn/text-base/parameters.h.svn-base +154 -0
  15. data/ext/vcftools/cpp/.svn/text-base/vcf_entry.cpp.svn-base +497 -0
  16. data/ext/vcftools/cpp/.svn/text-base/vcf_entry.h.svn-base +190 -0
  17. data/ext/vcftools/cpp/.svn/text-base/vcf_entry_getters.cpp.svn-base +421 -0
  18. data/ext/vcftools/cpp/.svn/text-base/vcf_entry_setters.cpp.svn-base +482 -0
  19. data/ext/vcftools/cpp/.svn/text-base/vcf_file.cpp.svn-base +495 -0
  20. data/ext/vcftools/cpp/.svn/text-base/vcf_file.h.svn-base +184 -0
  21. data/ext/vcftools/cpp/.svn/text-base/vcf_file_diff.cpp.svn-base +1282 -0
  22. data/ext/vcftools/cpp/.svn/text-base/vcf_file_filters.cpp.svn-base +1215 -0
  23. data/ext/vcftools/cpp/.svn/text-base/vcf_file_format_convert.cpp.svn-base +1138 -0
  24. data/ext/vcftools/cpp/.svn/text-base/vcf_file_index.cpp.svn-base +171 -0
  25. data/ext/vcftools/cpp/.svn/text-base/vcf_file_output.cpp.svn-base +3012 -0
  26. data/ext/vcftools/cpp/.svn/text-base/vcftools.cpp.svn-base +107 -0
  27. data/ext/vcftools/cpp/.svn/text-base/vcftools.h.svn-base +25 -0
  28. data/ext/vcftools/cpp/Makefile +46 -0
  29. data/ext/vcftools/cpp/dgeev.cpp +146 -0
  30. data/ext/vcftools/cpp/dgeev.h +43 -0
  31. data/ext/vcftools/cpp/output_log.cpp +79 -0
  32. data/ext/vcftools/cpp/output_log.h +34 -0
  33. data/ext/vcftools/cpp/parameters.cpp +535 -0
  34. data/ext/vcftools/cpp/parameters.h +154 -0
  35. data/ext/vcftools/cpp/vcf_entry.cpp +497 -0
  36. data/ext/vcftools/cpp/vcf_entry.h +190 -0
  37. data/ext/vcftools/cpp/vcf_entry_getters.cpp +421 -0
  38. data/ext/vcftools/cpp/vcf_entry_setters.cpp +482 -0
  39. data/ext/vcftools/cpp/vcf_file.cpp +495 -0
  40. data/ext/vcftools/cpp/vcf_file.h +184 -0
  41. data/ext/vcftools/cpp/vcf_file_diff.cpp +1282 -0
  42. data/ext/vcftools/cpp/vcf_file_filters.cpp +1215 -0
  43. data/ext/vcftools/cpp/vcf_file_format_convert.cpp +1138 -0
  44. data/ext/vcftools/cpp/vcf_file_index.cpp +171 -0
  45. data/ext/vcftools/cpp/vcf_file_output.cpp +3012 -0
  46. data/ext/vcftools/cpp/vcftools.cpp +107 -0
  47. data/ext/vcftools/cpp/vcftools.h +25 -0
  48. data/ext/vcftools/examples/.svn/all-wcprops +185 -0
  49. data/ext/vcftools/examples/.svn/dir-prop-base +6 -0
  50. data/ext/vcftools/examples/.svn/entries +1048 -0
  51. data/ext/vcftools/examples/.svn/prop-base/perl-api-1.pl.svn-base +5 -0
  52. data/ext/vcftools/examples/.svn/text-base/annotate-test.vcf.svn-base +37 -0
  53. data/ext/vcftools/examples/.svn/text-base/annotate.out.svn-base +23 -0
  54. data/ext/vcftools/examples/.svn/text-base/annotate.txt.svn-base +7 -0
  55. data/ext/vcftools/examples/.svn/text-base/annotate2.out.svn-base +52 -0
  56. data/ext/vcftools/examples/.svn/text-base/annotate3.out.svn-base +23 -0
  57. data/ext/vcftools/examples/.svn/text-base/cmp-test-a-3.3.vcf.svn-base +12 -0
  58. data/ext/vcftools/examples/.svn/text-base/cmp-test-a.vcf.svn-base +12 -0
  59. data/ext/vcftools/examples/.svn/text-base/cmp-test-b-3.3.vcf.svn-base +12 -0
  60. data/ext/vcftools/examples/.svn/text-base/cmp-test-b.vcf.svn-base +12 -0
  61. data/ext/vcftools/examples/.svn/text-base/cmp-test.out.svn-base +53 -0
  62. data/ext/vcftools/examples/.svn/text-base/concat-a.vcf.svn-base +21 -0
  63. data/ext/vcftools/examples/.svn/text-base/concat-b.vcf.svn-base +13 -0
  64. data/ext/vcftools/examples/.svn/text-base/concat-c.vcf.svn-base +19 -0
  65. data/ext/vcftools/examples/.svn/text-base/concat.out.svn-base +39 -0
  66. data/ext/vcftools/examples/.svn/text-base/invalid-4.0.vcf.svn-base +31 -0
  67. data/ext/vcftools/examples/.svn/text-base/isec-n2-test.vcf.out.svn-base +19 -0
  68. data/ext/vcftools/examples/.svn/text-base/merge-test-a.vcf.svn-base +17 -0
  69. data/ext/vcftools/examples/.svn/text-base/merge-test-b.vcf.svn-base +17 -0
  70. data/ext/vcftools/examples/.svn/text-base/merge-test-c.vcf.svn-base +15 -0
  71. data/ext/vcftools/examples/.svn/text-base/merge-test.vcf.out.svn-base +31 -0
  72. data/ext/vcftools/examples/.svn/text-base/perl-api-1.pl.svn-base +46 -0
  73. data/ext/vcftools/examples/.svn/text-base/query-test.out.svn-base +6 -0
  74. data/ext/vcftools/examples/.svn/text-base/shuffle-test.vcf.svn-base +12 -0
  75. data/ext/vcftools/examples/.svn/text-base/subset.SNPs.out.svn-base +10 -0
  76. data/ext/vcftools/examples/.svn/text-base/subset.indels.out.svn-base +18 -0
  77. data/ext/vcftools/examples/.svn/text-base/subset.vcf.svn-base +21 -0
  78. data/ext/vcftools/examples/.svn/text-base/valid-3.3.vcf.svn-base +30 -0
  79. data/ext/vcftools/examples/.svn/text-base/valid-4.0.vcf.stats.svn-base +104 -0
  80. data/ext/vcftools/examples/.svn/text-base/valid-4.0.vcf.svn-base +34 -0
  81. data/ext/vcftools/examples/.svn/text-base/valid-4.1.vcf.svn-base +37 -0
  82. data/ext/vcftools/examples/annotate-test.vcf +37 -0
  83. data/ext/vcftools/examples/annotate.out +23 -0
  84. data/ext/vcftools/examples/annotate.txt +7 -0
  85. data/ext/vcftools/examples/annotate2.out +52 -0
  86. data/ext/vcftools/examples/annotate3.out +23 -0
  87. data/ext/vcftools/examples/cmp-test-a-3.3.vcf +12 -0
  88. data/ext/vcftools/examples/cmp-test-a.vcf +12 -0
  89. data/ext/vcftools/examples/cmp-test-b-3.3.vcf +12 -0
  90. data/ext/vcftools/examples/cmp-test-b.vcf +12 -0
  91. data/ext/vcftools/examples/cmp-test.out +53 -0
  92. data/ext/vcftools/examples/concat-a.vcf +21 -0
  93. data/ext/vcftools/examples/concat-b.vcf +13 -0
  94. data/ext/vcftools/examples/concat-c.vcf +19 -0
  95. data/ext/vcftools/examples/concat.out +39 -0
  96. data/ext/vcftools/examples/invalid-4.0.vcf +31 -0
  97. data/ext/vcftools/examples/isec-n2-test.vcf.out +19 -0
  98. data/ext/vcftools/examples/merge-test-a.vcf +17 -0
  99. data/ext/vcftools/examples/merge-test-b.vcf +17 -0
  100. data/ext/vcftools/examples/merge-test-c.vcf +15 -0
  101. data/ext/vcftools/examples/merge-test.vcf.out +31 -0
  102. data/ext/vcftools/examples/perl-api-1.pl +46 -0
  103. data/ext/vcftools/examples/query-test.out +6 -0
  104. data/ext/vcftools/examples/shuffle-test.vcf +12 -0
  105. data/ext/vcftools/examples/subset.SNPs.out +10 -0
  106. data/ext/vcftools/examples/subset.indels.out +18 -0
  107. data/ext/vcftools/examples/subset.vcf +21 -0
  108. data/ext/vcftools/examples/valid-3.3.vcf +30 -0
  109. data/ext/vcftools/examples/valid-4.0.vcf +34 -0
  110. data/ext/vcftools/examples/valid-4.0.vcf.stats +104 -0
  111. data/ext/vcftools/examples/valid-4.1.vcf +37 -0
  112. data/ext/vcftools/extconf.rb +2 -0
  113. data/ext/vcftools/perl/.svn/all-wcprops +149 -0
  114. data/ext/vcftools/perl/.svn/entries +844 -0
  115. data/ext/vcftools/perl/.svn/prop-base/fill-aa.svn-base +5 -0
  116. data/ext/vcftools/perl/.svn/prop-base/fill-an-ac.svn-base +5 -0
  117. data/ext/vcftools/perl/.svn/prop-base/fill-ref-md5.svn-base +5 -0
  118. data/ext/vcftools/perl/.svn/prop-base/tab-to-vcf.svn-base +5 -0
  119. data/ext/vcftools/perl/.svn/prop-base/test.t.svn-base +5 -0
  120. data/ext/vcftools/perl/.svn/prop-base/vcf-annotate.svn-base +5 -0
  121. data/ext/vcftools/perl/.svn/prop-base/vcf-compare.svn-base +5 -0
  122. data/ext/vcftools/perl/.svn/prop-base/vcf-concat.svn-base +5 -0
  123. data/ext/vcftools/perl/.svn/prop-base/vcf-convert.svn-base +5 -0
  124. data/ext/vcftools/perl/.svn/prop-base/vcf-fix-newlines.svn-base +5 -0
  125. data/ext/vcftools/perl/.svn/prop-base/vcf-isec.svn-base +5 -0
  126. data/ext/vcftools/perl/.svn/prop-base/vcf-merge.svn-base +5 -0
  127. data/ext/vcftools/perl/.svn/prop-base/vcf-query.svn-base +5 -0
  128. data/ext/vcftools/perl/.svn/prop-base/vcf-shuffle-cols.svn-base +5 -0
  129. data/ext/vcftools/perl/.svn/prop-base/vcf-sort.svn-base +5 -0
  130. data/ext/vcftools/perl/.svn/prop-base/vcf-stats.svn-base +5 -0
  131. data/ext/vcftools/perl/.svn/prop-base/vcf-subset.svn-base +5 -0
  132. data/ext/vcftools/perl/.svn/prop-base/vcf-to-tab.svn-base +5 -0
  133. data/ext/vcftools/perl/.svn/prop-base/vcf-validator.svn-base +5 -0
  134. data/ext/vcftools/perl/.svn/text-base/ChangeLog.svn-base +84 -0
  135. data/ext/vcftools/perl/.svn/text-base/FaSlice.pm.svn-base +214 -0
  136. data/ext/vcftools/perl/.svn/text-base/Makefile.svn-base +12 -0
  137. data/ext/vcftools/perl/.svn/text-base/Vcf.pm.svn-base +2853 -0
  138. data/ext/vcftools/perl/.svn/text-base/VcfStats.pm.svn-base +681 -0
  139. data/ext/vcftools/perl/.svn/text-base/fill-aa.svn-base +103 -0
  140. data/ext/vcftools/perl/.svn/text-base/fill-an-ac.svn-base +56 -0
  141. data/ext/vcftools/perl/.svn/text-base/fill-ref-md5.svn-base +204 -0
  142. data/ext/vcftools/perl/.svn/text-base/tab-to-vcf.svn-base +92 -0
  143. data/ext/vcftools/perl/.svn/text-base/test.t.svn-base +376 -0
  144. data/ext/vcftools/perl/.svn/text-base/vcf-annotate.svn-base +1099 -0
  145. data/ext/vcftools/perl/.svn/text-base/vcf-compare.svn-base +1193 -0
  146. data/ext/vcftools/perl/.svn/text-base/vcf-concat.svn-base +310 -0
  147. data/ext/vcftools/perl/.svn/text-base/vcf-convert.svn-base +180 -0
  148. data/ext/vcftools/perl/.svn/text-base/vcf-fix-newlines.svn-base +97 -0
  149. data/ext/vcftools/perl/.svn/text-base/vcf-isec.svn-base +660 -0
  150. data/ext/vcftools/perl/.svn/text-base/vcf-merge.svn-base +577 -0
  151. data/ext/vcftools/perl/.svn/text-base/vcf-query.svn-base +272 -0
  152. data/ext/vcftools/perl/.svn/text-base/vcf-shuffle-cols.svn-base +89 -0
  153. data/ext/vcftools/perl/.svn/text-base/vcf-sort.svn-base +79 -0
  154. data/ext/vcftools/perl/.svn/text-base/vcf-stats.svn-base +160 -0
  155. data/ext/vcftools/perl/.svn/text-base/vcf-subset.svn-base +206 -0
  156. data/ext/vcftools/perl/.svn/text-base/vcf-to-tab.svn-base +112 -0
  157. data/ext/vcftools/perl/.svn/text-base/vcf-validator.svn-base +145 -0
  158. data/ext/vcftools/perl/ChangeLog +84 -0
  159. data/ext/vcftools/perl/FaSlice.pm +214 -0
  160. data/ext/vcftools/perl/Makefile +12 -0
  161. data/ext/vcftools/perl/Vcf.pm +2853 -0
  162. data/ext/vcftools/perl/VcfStats.pm +681 -0
  163. data/ext/vcftools/perl/fill-aa +103 -0
  164. data/ext/vcftools/perl/fill-an-ac +56 -0
  165. data/ext/vcftools/perl/fill-ref-md5 +204 -0
  166. data/ext/vcftools/perl/tab-to-vcf +92 -0
  167. data/ext/vcftools/perl/test.t +376 -0
  168. data/ext/vcftools/perl/vcf-annotate +1099 -0
  169. data/ext/vcftools/perl/vcf-compare +1193 -0
  170. data/ext/vcftools/perl/vcf-concat +310 -0
  171. data/ext/vcftools/perl/vcf-convert +180 -0
  172. data/ext/vcftools/perl/vcf-fix-newlines +97 -0
  173. data/ext/vcftools/perl/vcf-isec +660 -0
  174. data/ext/vcftools/perl/vcf-merge +577 -0
  175. data/ext/vcftools/perl/vcf-query +286 -0
  176. data/ext/vcftools/perl/vcf-shuffle-cols +89 -0
  177. data/ext/vcftools/perl/vcf-sort +79 -0
  178. data/ext/vcftools/perl/vcf-stats +160 -0
  179. data/ext/vcftools/perl/vcf-subset +206 -0
  180. data/ext/vcftools/perl/vcf-to-tab +112 -0
  181. data/ext/vcftools/perl/vcf-validator +145 -0
  182. data/ext/vcftools/website/.svn/all-wcprops +41 -0
  183. data/ext/vcftools/website/.svn/entries +238 -0
  184. data/ext/vcftools/website/.svn/prop-base/VCF-poster.pdf.svn-base +5 -0
  185. data/ext/vcftools/website/.svn/prop-base/favicon.ico.svn-base +5 -0
  186. data/ext/vcftools/website/.svn/prop-base/favicon.png.svn-base +5 -0
  187. data/ext/vcftools/website/.svn/text-base/Makefile.svn-base +6 -0
  188. data/ext/vcftools/website/.svn/text-base/README.svn-base +2 -0
  189. data/ext/vcftools/website/.svn/text-base/VCF-poster.pdf.svn-base +0 -0
  190. data/ext/vcftools/website/.svn/text-base/default.css.svn-base +250 -0
  191. data/ext/vcftools/website/.svn/text-base/favicon.ico.svn-base +0 -0
  192. data/ext/vcftools/website/.svn/text-base/favicon.png.svn-base +0 -0
  193. data/ext/vcftools/website/Makefile +6 -0
  194. data/ext/vcftools/website/README +2 -0
  195. data/ext/vcftools/website/VCF-poster.pdf +0 -0
  196. data/ext/vcftools/website/default.css +250 -0
  197. data/ext/vcftools/website/favicon.ico +0 -0
  198. data/ext/vcftools/website/favicon.png +0 -0
  199. data/ext/vcftools/website/img/.svn/all-wcprops +53 -0
  200. data/ext/vcftools/website/img/.svn/entries +300 -0
  201. data/ext/vcftools/website/img/.svn/prop-base/bg.gif.svn-base +5 -0
  202. data/ext/vcftools/website/img/.svn/prop-base/bgcode.gif.svn-base +5 -0
  203. data/ext/vcftools/website/img/.svn/prop-base/bgcontainer.gif.svn-base +5 -0
  204. data/ext/vcftools/website/img/.svn/prop-base/bgul.gif.svn-base +5 -0
  205. data/ext/vcftools/website/img/.svn/prop-base/header.gif.svn-base +5 -0
  206. data/ext/vcftools/website/img/.svn/prop-base/li.gif.svn-base +5 -0
  207. data/ext/vcftools/website/img/.svn/prop-base/quote.gif.svn-base +5 -0
  208. data/ext/vcftools/website/img/.svn/prop-base/search.gif.svn-base +5 -0
  209. data/ext/vcftools/website/img/.svn/text-base/bg.gif.svn-base +0 -0
  210. data/ext/vcftools/website/img/.svn/text-base/bgcode.gif.svn-base +0 -0
  211. data/ext/vcftools/website/img/.svn/text-base/bgcontainer.gif.svn-base +0 -0
  212. data/ext/vcftools/website/img/.svn/text-base/bgul.gif.svn-base +0 -0
  213. data/ext/vcftools/website/img/.svn/text-base/header.gif.svn-base +0 -0
  214. data/ext/vcftools/website/img/.svn/text-base/li.gif.svn-base +0 -0
  215. data/ext/vcftools/website/img/.svn/text-base/quote.gif.svn-base +0 -0
  216. data/ext/vcftools/website/img/.svn/text-base/search.gif.svn-base +0 -0
  217. data/ext/vcftools/website/img/bg.gif +0 -0
  218. data/ext/vcftools/website/img/bgcode.gif +0 -0
  219. data/ext/vcftools/website/img/bgcontainer.gif +0 -0
  220. data/ext/vcftools/website/img/bgul.gif +0 -0
  221. data/ext/vcftools/website/img/header.gif +0 -0
  222. data/ext/vcftools/website/img/li.gif +0 -0
  223. data/ext/vcftools/website/img/quote.gif +0 -0
  224. data/ext/vcftools/website/img/search.gif +0 -0
  225. data/ext/vcftools/website/src/.svn/all-wcprops +53 -0
  226. data/ext/vcftools/website/src/.svn/entries +300 -0
  227. data/ext/vcftools/website/src/.svn/text-base/docs.inc.svn-base +202 -0
  228. data/ext/vcftools/website/src/.svn/text-base/index.inc.svn-base +52 -0
  229. data/ext/vcftools/website/src/.svn/text-base/index.php.svn-base +80 -0
  230. data/ext/vcftools/website/src/.svn/text-base/license.inc.svn-base +27 -0
  231. data/ext/vcftools/website/src/.svn/text-base/links.inc.svn-base +13 -0
  232. data/ext/vcftools/website/src/.svn/text-base/options.inc.svn-base +654 -0
  233. data/ext/vcftools/website/src/.svn/text-base/perl_module.inc.svn-base +249 -0
  234. data/ext/vcftools/website/src/.svn/text-base/specs.inc.svn-base +18 -0
  235. data/ext/vcftools/website/src/docs.inc +202 -0
  236. data/ext/vcftools/website/src/index.inc +52 -0
  237. data/ext/vcftools/website/src/index.php +80 -0
  238. data/ext/vcftools/website/src/license.inc +27 -0
  239. data/ext/vcftools/website/src/links.inc +13 -0
  240. data/ext/vcftools/website/src/options.inc +654 -0
  241. data/ext/vcftools/website/src/perl_module.inc +249 -0
  242. data/ext/vcftools/website/src/specs.inc +18 -0
  243. data/lib/config.ru +9 -0
  244. data/lib/ngs_server/add.rb +9 -0
  245. data/lib/ngs_server/version.rb +1 -1
  246. data/lib/ngs_server.rb +55 -3
  247. data/ngs_server.gemspec +5 -2
  248. metadata +296 -6
data/bin/ngs_server CHANGED
@@ -1,58 +1,80 @@
1
1
  #!/usr/bin/env ruby
2
+ require 'optparse'
3
+
4
+ path = File.dirname(__FILE__)
5
+
6
+ $:.unshift File.join(path, "../lib")
2
7
 
3
- command = ARGV[0]
4
- path = `which ngs_server`
5
-
6
- puts Dir.pwd
7
- `ls ext/bamtools/binw`
8
-
9
- if command == 'start'
10
- require 'rubygems'
11
- require 'sinatra'
12
- require 'json'
13
-
14
- set :public, '.'
15
- set :port, "4569"
16
-
17
- bamtools_path = "ext/bamtools/bin/bamtools"
18
- vcftools_path = "~/Tools/vcftools_0.1.7/bin/vcf-query"
19
-
20
-
21
- get '/json/bam/*' do |path|
22
-
23
- content_type :json
24
- response['Access-Control-Allow-Origin'] = '*';
25
-
26
- # invoke with eg: base_url/json/bam/file=subset22-sorted.bam?min=30000000&max=30010000&segment=22
27
- json = `#{bamtools_path} convert -in data/#{path} -format json -region #{params["segment"]}:#{params["min"]}..#{params["max"]}`
28
- json
29
-
30
- end
31
-
32
- get '/json/vcf/*' do |path|
33
-
34
- content_type :json
35
- response['Access-Control-Allow-Origin'] = '*';
36
-
37
- # invoke with eg: base_url/json/vcf/file=ALL.2of4intersection.20100804.sites.vcf.gz?min=6992179&max=6992190&segment=1
38
- json = `#{vcftools_path} data/#{path} #{params["segment"]}:#{params["min"]}-#{params["max"]} -f '{"reference":"%CHROM","position":%POS,"ref":"%REF","alt":"%ALT","info":%INFO},'`
39
- json
40
-
41
- end
42
-
43
- get '/json/sources/:extension' do
44
-
45
- content_type :json
46
- response['Access-Control-Allow-Origin'] = '*';
8
+ require 'Ngs_server'
9
+
47
10
 
48
- # invoke with eg: base_url/json/vcf/file=ALL.2of4intersection.20100804.sites.vcf.gz?min=6992179&max=6992190&segment=1
49
- list = `find -L data -name *#{params['extension']} | awk -F/ '{ for(i=2; i<NF; i++) {printf("%s/", $i)} print $NF }'`
50
- list
11
+ require 'ngs_server/version'
12
+ require 'ngs_server/add'
13
+
51
14
 
15
+ options = {}
16
+ command = ""
17
+
18
+ optparse = OptionParser.new do |opts|
19
+ opts.banner = "Usage: ngs_server start|stop|add [options]"
20
+
21
+ opts.on( '-h', '--help', 'display this screen' ) do
22
+ # puts "ngs_server command options"
23
+ # puts "ngs_server start"
24
+
25
+ puts opts
26
+ puts "Examples:"
27
+ puts "\tngs_server start"
28
+ puts "\tngs_server start -p 4567 -d"
29
+ puts "\tngs_server add path_to_data_directory"
30
+ puts "\tngs_server stop"
31
+ exit
32
+ end
33
+
34
+ options[:port] = '4569'
35
+ opts.on( '-p', '--port PORT', 'specifies to port to listen on' ) do |f|
36
+ options[:port] = f
37
+ end
38
+
39
+ options[:daemonize] = ""
40
+ opts.on( '-d', '--daemonize', 'runs process in the background' ) do
41
+ options[:daemonize] = "-d";
42
+ end
43
+
44
+ # opts.on( '-C', '--config', 'configuration file for Thin server' ) do |f|
45
+ # options[:config] = f;
46
+ # end
47
+
52
48
  end
53
-
54
49
 
55
- elsif command == 'add-data'
50
+ optparse.parse!
51
+ command = ARGV[0]
56
52
 
57
53
 
58
- end
54
+
55
+ if (command == 'start')
56
+ # ngsrun options
57
+ rackup_path = File.join(path, '../lib/config.ru')
58
+ puts ">> NGS web server (version " + NgsServer::VERSION + ")"
59
+ if (options[:daemonize] == '-d')
60
+ puts ">> Listening on 0.0.0.0:" + options[:port]
61
+ else
62
+ puts ">> Listening on 0.0.0.0:" + options[:port] + ", CTRL+C to stop"
63
+ end
64
+ `thin -R #{rackup_path} -p #{options[:port]} #{options[:daemonize]} start`
65
+
66
+ #NgsServer.run!
67
+ elsif (command == 'stop')
68
+ rackup_path = File.join(path, '../lib/config.ru')
69
+ `thin -R #{rackup_path} -p #{options[:port]} stop`
70
+ elsif (command == 'add')
71
+ # source_path = File.absolute_path(ARGV[1])
72
+ # puts source_path
73
+ # file_name = File.basename(source_path)
74
+ # puts file_name
75
+ # data_dir_path = File.join(path,'../data', file_name)
76
+ # puts data_dir_path
77
+ # `ln -s #{source_path} #{data_dir_path}`
78
+ ngsadd ARGV[1]
79
+ end
80
+
@@ -2,8 +2,8 @@
2
2
  #dir = Dir.pwd
3
3
 
4
4
  #Dir.chdir("/Users/chase/Desktop/tmp_workspace/ngs_server/ext/bamtools/build")
5
- if !File.directory? "bin"
6
- `cmake .`
7
- end
5
+
6
+ `cmake .`
7
+
8
8
 
9
9
  #Dir.chdir(dir)
@@ -0,0 +1,28 @@
1
+ #
2
+ # 1) Compiling
3
+ # Type make in this directory
4
+ #
5
+ # 2) Installation
6
+ # Edit the BINDIR and MODDIR below as necessary or pass the PREFIX variable
7
+ # to the make command. When not set, the programs will be placed in "bin"
8
+ # and "lib" subdirectories in this directory.
9
+ # PREFIX="/install/to/path/prefix" make install
10
+ #
11
+ # Add the MODDIR to your PERL5LIB environment variable:
12
+ # export PERL5LIB=${PREFIX}/lib:${PERL5LIB}
13
+ #
14
+
15
+
16
+ ifndef PREFIX
17
+ export PREFIX = $(dir $(realpath $(lastword $(MAKEFILE_LIST))))
18
+ endif
19
+ export BINDIR = ${PREFIX}/bin
20
+ export MODDIR = ${PREFIX}/lib
21
+
22
+ DIRS = cpp perl
23
+ install:
24
+ @mkdir -p $(BINDIR); mkdir -p $(MODDIR); \
25
+ for dir in $(DIRS); do cd $$dir && $(MAKE) $(MAKEFLAGS) && cd ..; done
26
+
27
+ clean:
28
+ @for dir in $(DIRS); do cd $$dir && $(MAKE) clean && cd ..; done
@@ -0,0 +1,36 @@
1
+ License:
2
+ The program package is released under the GNU General Public License
3
+ version 3.0 (GPLv3).
4
+
5
+ Credits:
6
+ Adam Auton (cpp)
7
+ Petr Danecek (perl)
8
+
9
+ Compiling:
10
+ To compile and install VCFtools, you should type 'make' in the
11
+ vcftools folder. The perl scripts and cpp executable will be
12
+ installed in the /vcftools_(version_num)/bin/ folder. It is
13
+ recommended that you add this folder to you PATH.
14
+
15
+ Documentation:
16
+ The latest version of the documentation and examples of usage can be
17
+ found in the website subdirectory or go online:
18
+ http://vcftools.sourceforge.net/docs.html
19
+
20
+ Getting Help:
21
+ The best way to get help regarding VCFtools is to email the mailing
22
+ list: vcftools-help@lists.sourceforge.net
23
+
24
+ Citation:
25
+ If you make use of VCFtools in your research, we would appreciate a
26
+ citation of the following paper:
27
+
28
+ The Variant Call Format and VCFtools,
29
+ Petr Danecek, Adam Auton, Goncalo Abecasis, Cornelis A. Albers,
30
+ Eric Banks, Mark A. DePristo, Robert Handsaker, Gerton Lunter,
31
+ Gabor Marth, Stephen T. Sherry, Gilean McVean, Richard Durbin
32
+ and 1000 Genomes Project Analysis Group, Bioinformatics, 2011
33
+
34
+ http://dx.doi.org/10.1093/bioinformatics/btr330
35
+
36
+
@@ -0,0 +1,125 @@
1
+ K 25
2
+ svn:wc:ra_dav:version-url
3
+ V 34
4
+ /svnroot/vcftools/!svn/ver/620/cpp
5
+ END
6
+ vcf_entry.cpp
7
+ K 25
8
+ svn:wc:ra_dav:version-url
9
+ V 48
10
+ /svnroot/vcftools/!svn/ver/611/cpp/vcf_entry.cpp
11
+ END
12
+ dgeev.h
13
+ K 25
14
+ svn:wc:ra_dav:version-url
15
+ V 42
16
+ /svnroot/vcftools/!svn/ver/508/cpp/dgeev.h
17
+ END
18
+ vcftools.cpp
19
+ K 25
20
+ svn:wc:ra_dav:version-url
21
+ V 47
22
+ /svnroot/vcftools/!svn/ver/620/cpp/vcftools.cpp
23
+ END
24
+ output_log.cpp
25
+ K 25
26
+ svn:wc:ra_dav:version-url
27
+ V 49
28
+ /svnroot/vcftools/!svn/ver/457/cpp/output_log.cpp
29
+ END
30
+ parameters.cpp
31
+ K 25
32
+ svn:wc:ra_dav:version-url
33
+ V 49
34
+ /svnroot/vcftools/!svn/ver/620/cpp/parameters.cpp
35
+ END
36
+ vcf_entry.h
37
+ K 25
38
+ svn:wc:ra_dav:version-url
39
+ V 46
40
+ /svnroot/vcftools/!svn/ver/546/cpp/vcf_entry.h
41
+ END
42
+ vcf_file_index.cpp
43
+ K 25
44
+ svn:wc:ra_dav:version-url
45
+ V 53
46
+ /svnroot/vcftools/!svn/ver/584/cpp/vcf_file_index.cpp
47
+ END
48
+ vcftools.h
49
+ K 25
50
+ svn:wc:ra_dav:version-url
51
+ V 45
52
+ /svnroot/vcftools/!svn/ver/259/cpp/vcftools.h
53
+ END
54
+ vcf_file_filters.cpp
55
+ K 25
56
+ svn:wc:ra_dav:version-url
57
+ V 55
58
+ /svnroot/vcftools/!svn/ver/619/cpp/vcf_file_filters.cpp
59
+ END
60
+ vcf_file_diff.cpp
61
+ K 25
62
+ svn:wc:ra_dav:version-url
63
+ V 52
64
+ /svnroot/vcftools/!svn/ver/555/cpp/vcf_file_diff.cpp
65
+ END
66
+ output_log.h
67
+ K 25
68
+ svn:wc:ra_dav:version-url
69
+ V 47
70
+ /svnroot/vcftools/!svn/ver/457/cpp/output_log.h
71
+ END
72
+ vcf_entry_setters.cpp
73
+ K 25
74
+ svn:wc:ra_dav:version-url
75
+ V 56
76
+ /svnroot/vcftools/!svn/ver/612/cpp/vcf_entry_setters.cpp
77
+ END
78
+ parameters.h
79
+ K 25
80
+ svn:wc:ra_dav:version-url
81
+ V 47
82
+ /svnroot/vcftools/!svn/ver/620/cpp/parameters.h
83
+ END
84
+ vcf_file.cpp
85
+ K 25
86
+ svn:wc:ra_dav:version-url
87
+ V 47
88
+ /svnroot/vcftools/!svn/ver/620/cpp/vcf_file.cpp
89
+ END
90
+ vcf_file.h
91
+ K 25
92
+ svn:wc:ra_dav:version-url
93
+ V 45
94
+ /svnroot/vcftools/!svn/ver/620/cpp/vcf_file.h
95
+ END
96
+ vcf_file_format_convert.cpp
97
+ K 25
98
+ svn:wc:ra_dav:version-url
99
+ V 62
100
+ /svnroot/vcftools/!svn/ver/547/cpp/vcf_file_format_convert.cpp
101
+ END
102
+ dgeev.cpp
103
+ K 25
104
+ svn:wc:ra_dav:version-url
105
+ V 44
106
+ /svnroot/vcftools/!svn/ver/508/cpp/dgeev.cpp
107
+ END
108
+ vcf_entry_getters.cpp
109
+ K 25
110
+ svn:wc:ra_dav:version-url
111
+ V 56
112
+ /svnroot/vcftools/!svn/ver/612/cpp/vcf_entry_getters.cpp
113
+ END
114
+ Makefile
115
+ K 25
116
+ svn:wc:ra_dav:version-url
117
+ V 43
118
+ /svnroot/vcftools/!svn/ver/575/cpp/Makefile
119
+ END
120
+ vcf_file_output.cpp
121
+ K 25
122
+ svn:wc:ra_dav:version-url
123
+ V 54
124
+ /svnroot/vcftools/!svn/ver/620/cpp/vcf_file_output.cpp
125
+ END
@@ -0,0 +1,6 @@
1
+ K 10
2
+ svn:ignore
3
+ V 9
4
+ vcftools
5
+
6
+ END