Skip to content

Instantly share code, notes, and snippets.

@spacebat
Forked from nicferrier/*scratch*.el
Created March 29, 2013 22:13
Show Gist options
  • Save spacebat/5274043 to your computer and use it in GitHub Desktop.
Save spacebat/5274043 to your computer and use it in GitHub Desktop.
(let ((regex
(rx
(or bol bos (not (any "[")))
(group
(>= 2 (and (any "A-Z")(one-or-more (any "a-z"))))))))
(list
(replace-regexp-in-string regex "\\1" "[OneWordOrMore]")
(replace-regexp-in-string regex "\\1" "Onewordormore")
(replace-regexp-in-string regex "\\1" "OneWordormore")
(replace-regexp-in-string regex "\\1" "OneWordOrMore")))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment