Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Oniguruma – ny regex-motor i Ruby 1.9UnicodeCodepoint:   •   u00a4             u0020Property:   •   [[:alpha:]]   •   p{L}...
Upcoming SlideShare
Loading in …5
×

SHRUGSE regex cheat sheet

831 views

Published on

What's new in Ruby 1.9 regex? Presentation in Swedish: http://http.tv4.se/live/

Published in: Technology
  • Be the first to comment

  • Be the first to like this

SHRUGSE regex cheat sheet

  1. 1. Oniguruma – ny regex-motor i Ruby 1.9UnicodeCodepoint: • u00a4 u0020Property: • [[:alpha:]] • p{L} p{Ll} • p{S} p{Sc} "a^b¤c"Script: • p{Arabic}Negated: • P{L}Lookbehind • :(.*) $1 • (?<=:).* • (?<!:).*Possessive • p{L}*:.* • p{L}*+:.* • <b>.*</b> • <b>.*+</b>Named ref • /(?<day>dd):(?<mon>dd)/ =~ "24:12" hour • r = /(?<day>dd):(?<mon>dd)/ • "24.12".sub r, månad k<mon> och dag k<day>Recursive • ^(?<pal>|.|(?<prefix>.)g<pal>k<prefix+0>)$Du vet väl att det finns en heldagskurs I Regex? Mer info här: http://rekursiv.se/regexkurs

×