sequenceserver 0.7.7 → 0.7.8

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.

Potentially problematic release.


This version of sequenceserver might be problematic. Click here for more details.

@@ -1,104 +1,60 @@
1
1
  module SequenceServer
2
2
  module Customisation
3
+ ## When not commented out, this method is used to take a
4
+ ## sequence ID, and return a hyperlink that
5
+ ## replaces the hit in the BLAST output.
6
+ ##
7
+ ## Return the hyperlink to link to, or nil
8
+ ## to not not include a hyperlink.
9
+ ##
10
+ ## When this method
11
+ ## is commented out, the default link is used. The default
12
+ ## is a link to the full sequence of
13
+ ## the hit is displayed (if makeblastdb has been run with
14
+ ## -parse_seqids), or no link at all otherwise.
15
+ # def construct_custom_sequence_hyperlink(options)
16
+ # ## Example:
17
+ # ## sequence_id comes in like "psu|MAL13P1.200 | organism=Plasmodium_falciparum_3D7 | product=mitochondrial"
18
+ # ## output: "http://apiloc.bio21.unimelb.edu.au/apiloc/gene/MAL13P1.200"
19
+ # matches = options[:sequence_id].match(/^\s*psu\|(\S+) /)
20
+ # if matches #if the sequence_id conforms to our expectations
21
+ # # All is good. Return the hyperlink.
22
+ # return "http://apiloc.bio21.unimelb.edu.au/apiloc/gene/#{matches[1]}"
23
+ # else
24
+ # # Parsing the sequence_id didn't work. Don't include a hyperlink for this
25
+ # # sequence_id, but log that there has been a problem.
26
+ # settings.log.warn "Unable to parse sequence id `#{options[:sequence_id]}'"
27
+ # # Return nil so no hyperlink is generated.
28
+ # return nil
29
+ # end
30
+ # end
3
31
 
4
- # TODO: move this module to another file perhaps
5
- module Uniprot
6
- require 'yaml'
7
- SINV = YAML.load_file('./ext/uniprot/sinv.yml')
8
- end
9
-
10
- def default_link(options)
11
- case options[:sequence_id]
12
- when /^lcl\|([^\s]*)/
13
- id = $1
14
- (@all_retrievable_ids ||= []) << id
15
- "/get_sequence/?id=#{id}&db=#{options[:databases].join(' ')}" # several dbs... separate by ' '
16
- end
17
- end
18
-
19
- # Hook into SequenceServer's BLAST result formatting process to insert
20
- # links to Hymenopterabase Genome Browser, and/or Uniprot page
21
- # corresponding to a 'hit'.
22
- def construct_custom_sequence_hyperlinking_line(options)
23
- line = "><a href='#{url(default_link(options))}'>#{options[:sequence_id]}</a>"
24
- case options[:sequence_id]
25
- when /^lcl\|(PB.*-RA) /
26
- # pbar cds and protein
27
- id = "#{$1}:#{options[:hit_coordinates].join('..')}"
28
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/pbarbatus_1/?name=#{id}"
29
- line << " [<a href='#{browser}'>Genome Browser</a>]\n"
30
- when /^lcl\|pbar_(scf\d*) /
31
- # pbar genomic
32
- id = "#{$1}:#{options[:hit_coordinates].join('..')}"
33
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/pbarbatus_1/?name=#{id}"
34
- line << " [<a href='#{browser}'>Genome Browser</a>]\n"
35
- when /lcl\|SI2.2.0/ # => sinv
36
- sid = options[:sequence_id]
37
-
38
- # construct Hymenopterabase genome browser link
39
- bid = sid.match(/(Si_gnF.scaffold\d*)\[(\d*..\d*)\]/)[1..2].join(':')
40
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/sinvicta_1/?name=#{bid}"
41
-
42
- # construct uniprot link
43
- ukey = sid.match(/SI2.2.0_(\d*)/)[1]
44
- uid = Uniprot::SINV["SINV_#{ukey}"]
45
- uniprot = "http://www.uniprot.org/uniprot/#{uid}"
46
-
47
- # construct the entire line
48
- line << " [<a href='#{browser}'>Genome Browser</a>] [<a href='#{uniprot}'>Uniprot</a>]\n"
49
- when /^lcl\|(Si_gnF.scaffold\d*) /
50
- # sinv genomic
51
- id = "#{$1}:#{options[:hit_coordinates].join('..')}"
52
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/sinvicta_1/?name=#{id}"
53
- line << " [<a href='#{browser}'>Genome Browser</a>]\n"
54
- when /^lcl\|(LH\d*-RA) /
55
- # lhum cds and protein
56
- id = "#{$1}:#{options[:hit_coordinates].join('..')}"
57
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/lhumile_1/?name=#{id}"
58
- line << " [<a href='#{browser}'>Genome Browser</a>]\n"
59
- when /^lcl\|(scf\d*) /
60
- # lhum genomic
61
- id = "#{$1}:#{options[:hit_coordinates].join('..')}"
62
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/lhumile_1/?name=#{id}"
63
- line << " [<a href='#{browser}'>Genome Browser</a>]\n"
64
- when /^lcl\|(ACEP_\d*-RA) /
65
- # acep cds and protein
66
- id = $1.gsub(/EP_000/, '')
67
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/acephalotes_1/?name=#{id}"
68
- line << " [<a href='#{browser}'>Genome Browser</a>]\n"
69
- when /^lcl\|Acep_(scaffold\d*) /
70
- # acep genomic
71
- id = $1
72
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/acephalotes_1/?name=#{id}:#{options[:hit_coordinates].join('..')}"
73
- line << " [<a href='#{browser}'>Genome Browser</a>]\n"
74
- when /^lcl\|Cflo_(\d*)--/
75
- # cflo cds and protein
76
- id = "CFLO#{$1}-RA"
77
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/cfloridanus_1/?name=#{id}"
78
- line << " [<a href='#{browser}'>Genome Browser</a>]\n"
79
- when /^lcl\|Cflo_gn3.3_((scaffold\d*)|(C\d*)) /
80
- # cflo genomic
81
- id = "#{$1}:#{options[:hit_coordinates].join('..')}"
82
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/cfloridanus_1/?name=#{id}"
83
- line << " [<a href='#{browser}'>Genome Browser</a>]\n"
84
- when /^lcl\|Hsal_(\d*)--/
85
- # hsal cds and protein
86
- id = "HSAL#{$1}-RA"
87
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/hsaltator_1/?name=#{id}"
88
- line << " [<a href='#{browser}'>Genome Browser</a>]\n"
89
- when /^lcl\|Hsal_gn3.3_((scaffold\d*)|(C\d*)) /
90
- # hsal genomic
91
- id = "#{$1}:#{options[:hit_coordinates].join('..')}"
92
- browser = "http://genomes.arc.georgetown.edu/cgi-bin/gbrowse/hsaltator_1/?name=#{id}"
93
- line << " [<a href='#{browser}'>Genome Browser</a>]\n"
94
- else
95
- # Parsing the sequence_id didn't work. Don't include a hyperlink for this
96
- # sequence_id, but log that there has been a problem.
97
- settings.log.warn "Unable to parse sequence id `#{options[:sequence_id]}'"
98
- # Return nil so no hyperlink is generated.
99
- return nil
100
- end
101
- line
102
- end
32
+ ## Much like construct_custom_sequence_hyperlink, except
33
+ ## instead of just a hyperlink being defined, the whole
34
+ ## line as it appears in the blast results is generated.
35
+ ##
36
+ ## This is a therefore more flexible setup than is possible
37
+ ## with construct_custom_sequence_hyperlink, because doing
38
+ ## things such as adding two hyperlinks for the one hit
39
+ ## are possible.
40
+ ##
41
+ ## When this method is commented out, the behaviour is that
42
+ ## the construct_custom_sequence_hyperlink method is used,
43
+ ## or failing that the default method of that is used.
44
+ # def construct_custom_sequence_hyperlinking_line(options)
45
+ # matches = options[:sequence_id].match(/^\s*psu\|(\S+) /)
46
+ # if matches #if the sequence_id conforms to our expectations
47
+ # # All is good. Return the hyperlink.
48
+ # link1 = "http://apiloc.bio21.unimelb.edu.au/apiloc/gene/#{matches[1]}"
49
+ # link2 = "http://google.com/?q=#{matches[1]}"
50
+ # return "<a href='#{link1}'>ApiLoc page</a>, <a href='#{link2}'>Google search</a>"
51
+ # else
52
+ # # Parsing the sequence_id didn't work. Don't include a hyperlink for this
53
+ # # sequence_id, but log that there has been a problem.
54
+ # settings.log.warn "Unable to parse sequence id `#{options[:sequence_id]}'"
55
+ # # Return nil so no hyperlink is generated.
56
+ # return nil
57
+ # end
58
+ # end
103
59
  end
104
- end
60
+ end
@@ -147,7 +147,7 @@ $(document).ready(function(){
147
147
  $.onedb();
148
148
  });
149
149
 
150
- $('input:submit').click(function(){
150
+ $('#blast').submit(function(){
151
151
  var button = $(this);
152
152
 
153
153
  //prevent submitting another query while this one is being processed
@@ -1,7 +1,7 @@
1
1
  Gem::Specification.new do |s|
2
2
  # meta
3
3
  s.name = 'sequenceserver'
4
- s.version = '0.7.7'
4
+ s.version = '0.7.8'
5
5
  s.authors = ['Anurag Priyam', 'Ben J Woodcroft', 'Yannick Wurm']
6
6
  s.email = 'anurag08priyam@gmail.com'
7
7
  s.homepage = 'http://sequenceserver.com'
data/views/search.erb CHANGED
@@ -1,13 +1,12 @@
1
1
  <!DOCTYPE html>
2
2
  <html lang="en">
3
3
  <head>
4
- <title>Fourmidable: BLAST ant genomes, proteomes, and transcriptomes.</title>
4
+ <title>SequenceServer: Custom BLAST Server</title>
5
5
  <meta name="author" content="Anurag Priyam" />
6
6
  <meta name="author" content="Ben J. Woodcroft" />
7
7
  <meta name="author" content="Yannick Wurm" />
8
8
  <meta name="author" content="Cedric Wurm" />
9
- <meta name="description" content="BLAST search for ant genome sequences. A simple blast interface to search sequence of recently published ant genome."/>
10
- <meta name="keywords" content="ant genomes, blast search, fire ant genome, harvester ant genome, leafcutter ant genome, camponotus genome, harpegnathos genome."/>
9
+ <meta name="description" content="Custom BLAST server provided by SequenceServer (http://www.sequenceserver.com)"/>
11
10
  <meta content="text/html; charset=UTF-8" http-equiv="Content-Type"/>
12
11
  <script type="text/javascript" src="<%= uri('/js/jquery.js') %>"></script>
13
12
  <script type="text/javascript" src="<%= uri('/js/jquery.enablePlaceholder.min.js') %>"></script>
@@ -18,30 +17,16 @@
18
17
  <%# without a space after erb's closing tag, a / gets appended to css' path %>
19
18
  <link rel="stylesheet" media="screen" type="text/css" href="<%= uri('/css/bootstrap.min.css') %>" />
20
19
  <link rel="stylesheet" media="screen" type="text/css" href="<%= uri('/css/custom.css') %>" />
21
-
22
- <script type="text/javascript">
23
- var _gaq = _gaq || [];
24
- _gaq.push(['_setAccount', 'UA-471841-4']);
25
- _gaq.push(['_setDomainName', 'none']);
26
- _gaq.push(['_setAllowLinker', true]);
27
- _gaq.push(['_trackPageview']);
28
-
29
- (function() {
30
- var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
31
- ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
32
- var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
33
- })();
34
- </script>
35
20
  </head>
36
21
 
37
22
  <body>
38
23
  <div class="container">
39
24
  <div class="page">
40
25
  <div class="page-header" id="banner">
41
- <h1>BLAST Ant Genomes(s)</h1>
26
+ <h1>BLAST Sequence(s)</h1>
42
27
  </div>
43
28
 
44
- <form method="post" action="<%= uri('/#result') %>">
29
+ <form method="post" id="blast" action="<%= uri('/#result') %>">
45
30
  <div class="row">
46
31
  <div class="span12">
47
32
  <div class="offset-left sequence">
@@ -231,8 +216,7 @@
231
216
  </div>
232
217
 
233
218
  <div id="underbar">
234
- <p><a href="http://www.isb-sib.ch"><img src="http://antgenomes.org/img/sib120x74.png" width="40" height="25" alt="SIBlogo"/></a> Hosted by the Swiss Institute of Bioinformatics. BLAST search by <a href="http://www.sequenceserver.com">SequenceServer</a>.</p>
235
- <p>Please cite: <a href="http://www.biomedcentral.com/1471-2164/10/5/abstract">Wurm <em>et al</em> (2009) <strong>Fourmidable: a database for ant genomics.</strong> <em>BMC Genomics</em> 10:5</a> and the appropriate ant genome paper(s).</p>
219
+ <p>&copy; <a href='http://www.sequenceserver.com'>SequenceServer: BLAST search made easy!</a></p>
236
220
  </div>
237
221
  </div> <!-- /page -->
238
222
  </div> <!-- /container -->
metadata CHANGED
@@ -1,79 +1,61 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: sequenceserver
3
- version: !ruby/object:Gem::Version
4
- hash: 13
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.7.8
5
5
  prerelease:
6
- segments:
7
- - 0
8
- - 7
9
- - 7
10
- version: 0.7.7
11
6
  platform: ruby
12
- authors:
7
+ authors:
13
8
  - Anurag Priyam
14
9
  - Ben J Woodcroft
15
10
  - Yannick Wurm
16
11
  autorequire:
17
12
  bindir: bin
18
13
  cert_chain: []
19
-
20
- date: 2012-02-16 00:00:00 Z
21
- dependencies:
22
- - !ruby/object:Gem::Dependency
14
+ date: 2012-02-21 00:00:00.000000000Z
15
+ dependencies:
16
+ - !ruby/object:Gem::Dependency
23
17
  name: bundler
24
- prerelease: false
25
- requirement: &id001 !ruby/object:Gem::Requirement
18
+ requirement: &21083000 !ruby/object:Gem::Requirement
26
19
  none: false
27
- requirements:
28
- - - ">="
29
- - !ruby/object:Gem::Version
30
- hash: 3
31
- segments:
32
- - 0
33
- version: "0"
20
+ requirements:
21
+ - - ! '>='
22
+ - !ruby/object:Gem::Version
23
+ version: '0'
34
24
  type: :runtime
35
- version_requirements: *id001
36
- - !ruby/object:Gem::Dependency
37
- name: sinatra
38
25
  prerelease: false
39
- requirement: &id002 !ruby/object:Gem::Requirement
26
+ version_requirements: *21083000
27
+ - !ruby/object:Gem::Dependency
28
+ name: sinatra
29
+ requirement: &21082380 !ruby/object:Gem::Requirement
40
30
  none: false
41
- requirements:
42
- - - ">="
43
- - !ruby/object:Gem::Version
44
- hash: 31
45
- segments:
46
- - 1
47
- - 2
48
- - 0
31
+ requirements:
32
+ - - ! '>='
33
+ - !ruby/object:Gem::Version
49
34
  version: 1.2.0
50
35
  type: :runtime
51
- version_requirements: *id002
52
- - !ruby/object:Gem::Dependency
53
- name: ptools
54
36
  prerelease: false
55
- requirement: &id003 !ruby/object:Gem::Requirement
37
+ version_requirements: *21082380
38
+ - !ruby/object:Gem::Dependency
39
+ name: ptools
40
+ requirement: &21081860 !ruby/object:Gem::Requirement
56
41
  none: false
57
- requirements:
58
- - - ">="
59
- - !ruby/object:Gem::Version
60
- hash: 3
61
- segments:
62
- - 0
63
- version: "0"
42
+ requirements:
43
+ - - ! '>='
44
+ - !ruby/object:Gem::Version
45
+ version: '0'
64
46
  type: :runtime
65
- version_requirements: *id003
66
- description: |
67
- SequenceServer lets you rapidly set up a BLAST+ server with an intuitive user interface for use locally or over the web.
47
+ prerelease: false
48
+ version_requirements: *21081860
49
+ description: ! 'SequenceServer lets you rapidly set up a BLAST+ server with an intuitive
50
+ user interface for use locally or over the web.
68
51
 
52
+ '
69
53
  email: anurag08priyam@gmail.com
70
- executables:
54
+ executables:
71
55
  - sequenceserver
72
56
  extensions: []
73
-
74
57
  extra_rdoc_files: []
75
-
76
- files:
58
+ files:
77
59
  - lib/sequenceserver.rb
78
60
  - lib/sequenceserver/database_formatter.rb
79
61
  - lib/sequenceserver/sequencehelpers.rb
@@ -114,49 +96,31 @@ files:
114
96
  - sequenceserver.gemspec
115
97
  - bin/sequenceserver
116
98
  homepage: http://sequenceserver.com
117
- licenses:
99
+ licenses:
118
100
  - SequenceServer (custom)
119
- post_install_message: |+
120
-
121
- ------------------------------------------------------------------------
122
- Thank you for installing SequenceServer :)!
123
-
124
- To launch SequenceServer execute 'sequenceserver' from command line.
125
-
126
- $ sequenceserver
127
-
128
-
129
- Visit http://sequenceserver.com for more.
130
- ------------------------------------------------------------------------
131
-
101
+ post_install_message: ! "\n------------------------------------------------------------------------\n
102
+ \ Thank you for installing SequenceServer :)!\n\n To launch SequenceServer execute
103
+ 'sequenceserver' from command line.\n\n $ sequenceserver\n\n\n Visit http://sequenceserver.com
104
+ for more.\n------------------------------------------------------------------------\n\n"
132
105
  rdoc_options: []
133
-
134
- require_paths:
106
+ require_paths:
135
107
  - lib
136
- required_ruby_version: !ruby/object:Gem::Requirement
108
+ required_ruby_version: !ruby/object:Gem::Requirement
137
109
  none: false
138
- requirements:
139
- - - ">="
140
- - !ruby/object:Gem::Version
141
- hash: 3
142
- segments:
143
- - 0
144
- version: "0"
145
- required_rubygems_version: !ruby/object:Gem::Requirement
110
+ requirements:
111
+ - - ! '>='
112
+ - !ruby/object:Gem::Version
113
+ version: '0'
114
+ required_rubygems_version: !ruby/object:Gem::Requirement
146
115
  none: false
147
- requirements:
148
- - - ">="
149
- - !ruby/object:Gem::Version
150
- hash: 3
151
- segments:
152
- - 0
153
- version: "0"
116
+ requirements:
117
+ - - ! '>='
118
+ - !ruby/object:Gem::Version
119
+ version: '0'
154
120
  requirements: []
155
-
156
121
  rubyforge_project:
157
- rubygems_version: 1.8.11
122
+ rubygems_version: 1.8.10
158
123
  signing_key:
159
124
  specification_version: 3
160
125
  summary: iPod of BLAST searching
161
126
  test_files: []
162
-