Sha256: ceac6807a63e86fc74748cb6b00f6af3effd854e28503fffb813b656c1caf41b
Contents?: true
Size: 773 Bytes
Versions: 2
Compression:
Stored size: 773 Bytes
Contents
module Kernel # Offline repo activate #def mount_modules(target_folder= File.join(Dir.pwd,"{module,modules}","{gem,gems}") ) # Dir.glob(File.join(target_folder,"**","lib")).select{|f| File.directory?(f)}.each do |one_path| # $LOAD_PATH.unshift one_path # end #end # require by absolute path directory's files def require_directory(folder) Dir.glob(File.join(folder,"**","*.{rb,ru}")).each do |file_path| require file_path end end # require sender relative directory's files # return the directory and the sub directories file names (rb/ru) def require_relative_directory(folder) Dir.glob(File.join(Loader.caller_folder,folder,"**","*.{rb,ru}")).each do |one_path| require one_path end return nil end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
loader-1.0.2 | lib/loader/require.rb |
loader-1.0.1 | lib/loader/require.rb |