Skip to content

Instantly share code, notes, and snippets.

@no6v
Forked from jugyo/circle.rb
Created March 12, 2012 08:58
Show Gist options
  • Save no6v/2020796 to your computer and use it in GitHub Desktop.
Save no6v/2020796 to your computer and use it in GitHub Desktop.
Earthquake.init do
command :circle do |m|
text = m[1].unpack("U*").map {|i|
[*case i
when 97..122 # a-z
i + 0x24d0 - 97
when 65..90
i + 0x24b6 - 65
when 49..57
i + 0x245f - 48
when 48
0x24ea
else
i
end].pack("U")
}.join
input ":update #{text}"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment