projects
/
chise
/
ruby.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
update.
[chise/ruby.git]
/
chise
/
path.rb
diff --git
a/chise/path.rb
b/chise/path.rb
index
9e695f6
..
1d68d04
100755
(executable)
--- a/
chise/path.rb
+++ b/
chise/path.rb
@@
-11,10
+11,10
@@
end
class Pathname
def escape
- s = self.basename.to_s.gsub(/([\/%]+)/n){
+ s = self.to_s.gsub(/([\/%]+)/n){
"%" + $1.unpack("H2" * $1.size).join("%").upcase
}
- Pathname.new(self.dirname+s)
+ Pathname.new(s)
end
def unescape # copied from cgi.rb