Sha256: 023144bd3db099be433273602876e674c27fd721e9cbabe72b845df39e27d9b5
Contents?: true
Size: 1.27 KB
Versions: 2
Compression:
Stored size: 1.27 KB
Contents
# backends.rb: all the backends # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 # USA require 'ctioga2/data/backends/backend' # We try to look for all files under a ctioga2/metabuilder/types # directory anywhere on the $: path files = [] for dir in $: Dir[dir + '/ctioga2/data/backends/backends/**/*'].each do |f| f =~ /ctioga2\/data\/backends\/backends\/(.*)\.[^.]+$/ files << $1 end end for file in files.uniq begin require "ctioga2/data/backends/backends/#{file}" rescue Exception => e warn { "There was a problem trying to load 'ctioga2/data/backends/backends/#{file}': " } warn { "#{e.inspect}" } end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
ctioga2-0.2 | lib/ctioga2/data/backends/backends.rb |
ctioga2-0.1 | lib/ctioga2/data/backends/backends.rb |