From 99947702257a9452a33c8af4c2c1092ad3c207d1 Mon Sep 17 00:00:00 2001 From: Brandon Mathis Date: Sun, 13 Jan 2013 23:03:55 -0600 Subject: [PATCH] Made it easy to optionally use RubyPython for pygments, closes #923 --- plugins/pygments_code.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/plugins/pygments_code.rb b/plugins/pygments_code.rb index 4ea868d..0ce0594 100644 --- a/plugins/pygments_code.rb +++ b/plugins/pygments_code.rb @@ -3,6 +3,10 @@ require './plugins/config' require 'pygments' require 'fileutils' require 'digest/md5' +begin # Make it easy for folks to use rubypython if they like + require 'rubypython' +rescue LoadError # rubypython is not installed +end PYGMENTS_CACHE_DIR = File.expand_path('../../.pygments-cache', __FILE__) FileUtils.mkdir_p(PYGMENTS_CACHE_DIR)