Skip to content

Strong: Make Your Strings Stronger in Lua

Posted on:April 29, 2011

For the last few days I’ve been working on a library called “strong”. It’s a string enhancement library for Lua. Strong adds a few operators to strings, and many methods to Lua’s string library. I’ve already written more information in the README and the wiki, which you can go to for more information. Here’s the direct link to the GitHub repo by the way.

After much testing and refinements, I’ve just released version 1.0 of the library. Finally, here’s an example straight from the README of a little of what the lib can do:

s = "Hello world.\nBoo. This is cool.\nHey!"

for line in s:lines() do
  local sentences = line / '.%s*'

  for _, s in pairs(sentences)
    print(s:capitalize())
  end
end

Enjoy!

EDIT: Here’s the project page.