Sha256: 2c91a7416869e95c07b3eaa17c57ce36ff42184928175d75e8636c7bc6545de9

Contents?: true

Size: 253 Bytes

Versions: 15

Compression:

Stored size: 253 Bytes

Contents

module PathSep
  def /(right)
    s1 = self.to_s.dup
    s2 = right.to_s.dup
    s1 << "/" unless s2.end_with?("/") || s2.start_with?("/")
    path = s1 + s2
    path.gsub!("//", "/")
    path
  end
end

String.include(PathSep)
Symbol.include(PathSep)

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
runeblog-0.2.32 lib/pathmagic.rb
runeblog-0.2.31 lib/pathmagic.rb
runeblog-0.2.30 lib/pathmagic.rb
runeblog-0.2.29 lib/pathmagic.rb
runeblog-0.2.28 lib/pathmagic.rb
runeblog-0.2.27 lib/pathmagic.rb
runeblog-0.2.26 lib/pathmagic.rb
runeblog-0.2.25 lib/pathmagic.rb
runeblog-0.2.24 lib/pathmagic.rb
runeblog-0.2.23 lib/pathmagic.rb
runeblog-0.2.22 lib/pathmagic.rb
runeblog-0.2.18 lib/pathmagic.rb
runeblog-0.2.17 lib/pathmagic.rb
runeblog-0.2.16 lib/pathmagic.rb
runeblog-0.2.15 lib/pathmagic.rb