Skip to content

Instantly share code, notes, and snippets.

@davispuh davispuh/test2.rb
Created Sep 23, 2013

What would you like to do?
#!/usr/bin/env ruby
#encoding: utf-8
require 'win32/registry'
begin"SOFTWARE\doesnt_exist") do |reg|
rescue Win32::Registry::Error => e
message = e.message
puts message.encoding
puts message
puts message.inspect
puts message.force_encoding("windows-1257")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.