Skip to content

Commit

Permalink
p
Browse files Browse the repository at this point in the history
  • Loading branch information
haohuoyao committed Oct 17, 2018
1 parent 4712e26 commit b6cf2b2
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion a.gemspec
Expand Up @@ -12,7 +12,7 @@ Gem::Specification.new do |s|
s.files += Dir["lib/commands/*.rb"]
s.executables << "a"

#s.require_paths = ['lib']
s.require_paths << 'lib'
s.required_ruby_version = '>= 2.0.0'

end
6 changes: 3 additions & 3 deletions bin/a
Expand Up @@ -35,9 +35,9 @@ EOT
def main

begin
require 'pathname'
require(File.join(File.dirname(__FILE__),'..','lib','commands',target.downcase))

#require 'pathname'
#require(File.join(File.dirname(__FILE__),'..','lib','commands',target.downcase))
require File.join('commands',target.downcase)
rescue LoadError

puts "the #{target} not exist"
Expand Down
8 changes: 7 additions & 1 deletion lib/a.rb
@@ -1 +1,7 @@
# puts rand
module A
class << self
def info
puts rand
end
end
end

0 comments on commit b6cf2b2

Please sign in to comment.