Sha256: 45166d36f3a643903ac6a000bb6eaa1b814a5c10305803b32bd476cdf2d99484
Contents?: true
Size: 614 Bytes
Versions: 15
Compression:
Stored size: 614 Bytes
Contents
module Jets::Command class Help class << self def text(namespaced_command) file = namespaced_command.to_s.gsub(':','/') path = File.expand_path("../help/#{file}.md", __FILE__) return IO.read(path) if File.exist?(path) # Also look up for a help folder within the current command folder called_from = caller.first.split(':').first unnamespaced_command = namespaced_command.to_s.split(':').last path = File.expand_path("../help/#{unnamespaced_command}.md", called_from) return IO.read(path) if File.exist?(path) end end end end
Version data entries
15 entries across 15 versions & 1 rubygems