Skip to content

ponzao/komeetta

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

53 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Komeetta is project containing a functional-style list and list functions in Lua. Perhaps in the future it will contain other functional stuff as well. The word "komeetta" is Finnish and means "comet", but because that word is already used in another Lua project I decided to use the Finnish translation. "Comet" is a good word for a list implementation because a comet has a head and a tail.

Usage:
require("komeetta")
list = komeetta.List:new(5, -3, 1) -- (5 -3 1)
sorted_list = list:sort() -- (-3 1 5)

None of the functions will modify the original collection. So you can safely chain them together like this:
...
komeetta.List:new(5, -3, 1):sort():reverse() -- (5 1 -3)

To run the tests you will need luaspec (http://github.com/mirven/luaspec). The specs presume you have installed luaspec via luarocks, if this is not the case then you need to modify the "require"-statements in the specs. Once everything is set you need to run the "run_specs"-file.

I would really like to have something similar to Maven in the Lua world.

About

Functional-style list and list functions in Lua.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages