Skip to content
This repository has been archived by the owner on Jun 10, 2018. It is now read-only.

Commit

Permalink
Update README with append/prepend api changes
Browse files Browse the repository at this point in the history
  • Loading branch information
josh committed Jul 18, 2011
1 parent 3896a66 commit df16e25
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions README.md
Expand Up @@ -9,8 +9,8 @@ implement search paths, load paths, and the like.
Find Ruby files in this project: Find Ruby files in this project:


trail = Hike::Trail.new "/Users/sam/Projects/hike" trail = Hike::Trail.new "/Users/sam/Projects/hike"
trail.extensions.push ".rb" trail.append_extension ".rb"
trail.paths.push "lib", "test" trail.append_path "lib", "test"


trail.find "hike/trail" trail.find "hike/trail"
# => "/Users/sam/Projects/hike/lib/hike/trail.rb" # => "/Users/sam/Projects/hike/lib/hike/trail.rb"
Expand All @@ -21,8 +21,8 @@ Find Ruby files in this project:
Explore your Ruby load path: Explore your Ruby load path:


trail = Hike::Trail.new "/" trail = Hike::Trail.new "/"
trail.extensions.push ".rb", ".bundle" trail.append_extension ".rb", ".bundle"
trail.paths.replace $: trail.append_path *$:


trail.find "net/http" trail.find "net/http"
# => "/Users/sam/.rvm/rubies/ree-1.8.7-2010.02/lib/ruby/1.8/net/http.rb" # => "/Users/sam/.rvm/rubies/ree-1.8.7-2010.02/lib/ruby/1.8/net/http.rb"
Expand All @@ -33,7 +33,7 @@ Explore your Ruby load path:
Explore your shell path: Explore your shell path:


trail = Hike::Trail.new "/" trail = Hike::Trail.new "/"
trail.paths.replace ENV["PATH"].split(":") trail.append_path *ENV["PATH"].split(":")


trail.find "ls" trail.find "ls"
# => "/bin/ls" # => "/bin/ls"
Expand Down

0 comments on commit df16e25

Please sign in to comment.