virust-locator-ruby 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 88e66376125b0fe1536e2c1873711175fcd2796fdfd325b43677689324442625
4
- data.tar.gz: 15b86c8621848cb4f563d607a1f1d8a551e86b29d4ae2ef420c556fa33d32d3c
3
+ metadata.gz: 4f707c3b610e396fa91ab80019bd33fef85a11537a02a972952da29d27e5eae5
4
+ data.tar.gz: 4530ebbc8774b4a9729015b2373149ecaa68e74d1bf03406e7adcee75e0e0d90
5
5
  SHA512:
6
- metadata.gz: 38130025373b81803d199247c24ed091772cfaac1b1ea201606033e417adab28175dec1923a4a6937a8737a75f1a265bee99cee708472f6ac1d2e8c0bf44c6f4
7
- data.tar.gz: ec69e354e51058e57ccdca96aef36bb692e17d9cb977fbbf6d8b4010aa3a98162e2e05f08c67027e0f2ee1cf39dbc5c4a372380bfc172dfd02d507edf0841870
6
+ metadata.gz: c301755f05d3f6a0e1936a4ad1cbccd7db99f0d66831064f5d1293b899eefb22bb86c169f88de27444480b122659ebd91847c72678724d2dc12573ed25ba8ac9
7
+ data.tar.gz: 253da967570441b088502d3ed70cb11e20d52c71c7b9133208daba4bb1872c80e387b21bda8d5b00df66255f99883f088767a3a5c0f65980da0c67f2f548aa4d
data/README.md CHANGED
@@ -45,6 +45,12 @@ Options:
45
45
 
46
46
  ## Change Log
47
47
 
48
+ ### v0.3.0
49
+
50
+ 1. Fixed a bug for displaying the aligned sequences.
51
+
52
+ 2. Now allow multiple sequences to be run at one time. When running multiple sequences in one query (seperate each with [whitespace]), return object is the locator results one line per query.
53
+
48
54
  ### v0.2.0
49
55
 
50
56
  1. Fixed a bug for showing the aligned sequences.
@@ -10,7 +10,7 @@ module VirustLocator
10
10
  # Locator.exec("GAAAGCATAGTAATATGGGGAAAGACTCCTAAA")
11
11
  # => "3681\t3713\t100\tfalse\tGAAAGCATAGTAATATGGGGAAAGACTCCTAAA\tGAAAGCATAGTAATATGGGGAAAGACTCCTAAA"
12
12
  module Locator
13
- def self.exec(query, type = "nt", algorithm = "1", ref = "HXB2") # rubocop:disable Metrics/MethodLength
13
+ def self.init # rubocop:disable Metrics/MethodLength
14
14
  file = case RUBY_PLATFORM
15
15
  when /arm64-darwin/
16
16
  "virust-locator-aarch64-apple-darwin"
@@ -25,12 +25,15 @@ module VirustLocator
25
25
  else
26
26
  raise "Unsupported platform: #{RUBY_PLATFORM}"
27
27
  end
28
-
29
28
  file = File.join(File.dirname(__FILE__), "runnable", file)
30
- safe_file = Shellwords.escape(file)
31
29
  raise "Excecutable file not found: #{file}" unless File.exist?(file)
32
30
 
33
- `#{safe_file} -q #{Shellwords.escape(query)} -t #{Shellwords.escape(type)} -a #{Shellwords.escape(algorithm)} -r #{Shellwords.escape(ref)}`.strip # rubocop:disable Layout/LineLength
31
+ Shellwords.escape(file)
32
+ end
33
+
34
+ def self.exec(query, type = "nt", algorithm = "1", ref = "HXB2")
35
+ safe_file = init
36
+ `#{safe_file} -q #{query} -t #{type} -a #{algorithm} -r #{ref}`.strip
34
37
  end
35
38
  end
36
39
  end
@@ -3,5 +3,5 @@
3
3
 
4
4
  module VirustLocator
5
5
  # The version of the virust-locator-ruby gem.
6
- VERSION = "0.2.0"
6
+ VERSION = "0.3.0"
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: virust-locator-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shuntai Zhou