Sha256: 0ba15e464f2d8770359a36c2ed0804384b3c36565eb4ae07af4a7dcd77b34bdd
Contents?: true
Size: 671 Bytes
Versions: 11
Compression:
Stored size: 671 Bytes
Contents
Mode = :strict name = "windows" found = Dir.glob(File.join("/mnt/WinVault/Alexandrial/Technical", "**/**")).reject { |f| File.directory?(f) }.select { |v| vv = File.basename(v) case Mode when :strict res1 = (/^#{name}[-,_,.,\s]/i =~ vv) res2 = (vv =~ /[\(,-,_,.,\s]#{name}[\),-,_,.,\s]/i) res3 = (vv =~ /[-,_,.,\s]#{name}\z/i) puts "#{vv} : #{res1} / #{res2} / #{res3}" (res1 or res2 or res3) else res1 = (vv =~ /[(,-,_,.,\s]#{name}[),-,_,.,\s]/i) res2 = (vv =~ /[(,-,_,.,\s]#{name}/i) res3 = (vv =~ /#{name}[),-,_,.,\s]/i) puts "#{vv} : #{res1} / #{res2} / #{res3}" (res1 or res2 or res3) end } p found
Version data entries
11 entries across 11 versions & 1 rubygems