Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Email address for NCBI Entrez is given with Bio::NCBI.default_email=.

  • Loading branch information...
commit 9c8ef18a20c49f17d5b89aa1db5819b2c8ee9b1d 1 parent 7a71796
@ngoto ngoto authored
View
5 bin/bioruby
@@ -6,7 +6,7 @@
# Toshiaki Katayama <k@bioruby.org>
# License:: The Ruby License
#
-# $Id: bioruby,v 1.21 2007/07/26 10:46:46 k Exp $
+# $Id:$
#
begin
@@ -26,6 +26,9 @@ Bio::Shell::Setup.new
# loading workspace and command history
Bio::Shell.load_session
+# sets default email address for Entrez eUtils.
+Bio::NCBI.default_email ||= 'staff@bioruby.org'
+
# main loop
if Bio::Shell.cache[:rails]
Bio::Shell.cache[:rails].join
View
2  sample/demo_ncbi_rest.rb
@@ -26,6 +26,8 @@
require 'bio'
+Bio::NCBI.default_email = 'staff@bioruby.org'
+
#if __FILE__ == $0
gbopts = {"db"=>"nuccore", "rettype"=>"gb"}
View
2  sample/demo_pubmed.rb
@@ -27,6 +27,8 @@
require 'bio'
+Bio::NCBI.default_email = 'staff@bioruby.org'
+
#if __FILE__ == $0
puts "=== instance methods ==="
View
2  sample/pmfetch.rb
@@ -23,6 +23,8 @@
require 'bio'
+Bio::NCBI.default_email = 'staff@bioruby.org'
+
if ARGV[0] =~ /\A\-f/
ARGV.shift
form = ARGV.shift
View
2  sample/pmsearch.rb
@@ -23,6 +23,8 @@
require 'bio'
+Bio::NCBI.default_email = 'staff@bioruby.org'
+
if ARGV[0] =~ /\A\-f/
ARGV.shift
form = ARGV.shift
View
4 test/functional/bio/io/test_pubmed.rb
@@ -115,6 +115,8 @@ class FuncTestPubmed < Test::Unit::TestCase
include FuncTestPubmedCommon
def setup
+ Bio::NCBI.default_email = 'staff@bioruby.org'
+ #$stderr.puts Bio::NCBI.default_tool
@pm = Bio::PubMed.new
end
end #class FuncTestPubmed
@@ -124,6 +126,8 @@ class FuncTestPubmedClassMethod < Test::Unit::TestCase
include FuncTestPubmedCommon
def setup
+ Bio::NCBI.default_email = 'staff@bioruby.org'
+ #$stderr.puts Bio::NCBI.default_tool
@pm = Bio::PubMed
end
end #class FuncTestPubmedClassMethod
Please sign in to comment.
Something went wrong with that request. Please try again.