From d3278b9d1c19f78cecc4bc92aa28f341443350eb Mon Sep 17 00:00:00 2001 From: wmorgan Date: Wed, 24 Jan 2007 19:15:50 +0000 Subject: [PATCH] automatically connect to all sources at once upon startup git-svn-id: svn://rubyforge.org/var/svn/sup/trunk@279 5c8cc53c-5e98-4d25-b20a-d8db53a31250 --- bin/sup | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/bin/sup b/bin/sup index a45f2b5..2038fbd 100644 --- a/bin/sup +++ b/bin/sup @@ -102,7 +102,17 @@ begin Logger.make_buf bm.draw_screen - imode.load_threads :num => ibuf.content_height, :when_done => lambda { reporting_thread { sleep 1; PollManager.poll } } + Index.usual_sources.each do |s| + reporting_thread do + begin + s.connect + rescue SourceError => e + Redwood::log "Fatal error loading from #{s}: #{e.message}" + end + end if s.respond_to? :connect + end + + imode.load_threads :num => ibuf.content_height, :when_done => lambda { reporting_thread { sleep 1; PollManager.poll } } PollManager.start_thread -- 2.45.2