re = /(?i)[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}/m
str = 'f36b9decc73e40bfb9a6250198a83fc0/SharePoint/source_28D4CE4DFC53AABB34B41E17BE9DEBBC/item__6761c90b-c1e0-4a91-b72c-e044e5b8cc56_1.0
F36B9DECC73E40BFB9A6250198A83FC0/SHAREPOINT/SOURCE_28D4CE4DFC53AABB34B41E17BE9DEBBC/ITEM__6761C90B-C1E0-4A91-B72C-E044E5B8CC56_1.0'
# Print the match result
str.scan(re) do |match|
puts match.to_s
end
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for Ruby, please visit: http://ruby-doc.org/core-2.2.0/Regexp.html