sup

A curses threads-with-tags style email client

sup.git

git clone https://supmua.dev/git/sup/
commit 6f8c9bf8ae6d65fd41298aebb78b846e61297292
parent e0ad3a8dae3d7227a9c231dc92c3de299d1a4fa2
Author: Anthony Martinez <pi+sup@pihost.us>
Date:   Sun,  3 Jan 2010 12:38:52 -0700

sup-convert-ferret-index: require xapian gem before starting

Make it complain about not having Xapian *before* starting the state dump, so
it doesn't get to step 3 and suddenly find out that it can't load Xapian.

Diffstat:
M bin/sup-convert-ferret-index | 6 ++++++
1 file changed, 6 insertions(+), 0 deletions(-)
diff --git a/bin/sup-convert-ferret-index b/bin/sup-convert-ferret-index
@@ -42,6 +42,12 @@ def run cmd
   puts
 end
 
+begin
+  require 'xapian'
+rescue LoadError
+  Trollop::die "you don't have the xapian gem installed, so this script won't do much for you--`gem install xapian` (or xapian-full) first"
+end
+
 Redwood::start
 index = Redwood::Index.init
 Trollop::die "you appear to already have a Xapian index--delete #{File.join(Redwood::BASE_DIR, "xapian")} if you really want to do this" unless Redwood::Index.is_a_deprecated_ferret_index?