module Pry::Exercismun
Constants
- VERSION
Public Instance Methods
process()
click to toggle source
# File lib/pry/exercismun.rb, line 23 def process lines = `exercism fetch` puts Pry::Exercismun.short_fetch lines end
short_fetch(string)
click to toggle source
# File lib/pry/exercismun.rb, line 56 def short_fetch string string.lines do |line| if a = line.gsub!('Fetched ', '') lang, exercise = a.split '/' output.puts "#{lang.capitalize}: #{exercise}" end end end
submit()
click to toggle source
# File lib/pry/exercismun.rb, line 39 def submit unless args[0].nil? || args[0].empty? name = "#{args[0]}.rb" else dir = Dir.pwd file = dir.split('/').last name = "#{dir+'/'+file}.rb" end `exercism submit #{name}` end