waxlab/nebula
1
0
Fork
You've already forked nebula
0
Single Lua script for portable builds.
  • Lua 59.8%
  • C 40.2%
2026年06月25日 02:53:06 -03:00
src pre: builder packaging and beginning of C module 2026年06月25日 02:53:06 -03:00
.editorconfig pre: builder packaging and beginning of C module 2026年06月25日 02:53:06 -03:00
build pre: builder packaging and beginning of C module 2026年06月25日 02:53:06 -03:00
LICENSE Initial commit 2026年06月02日 09:17:25 -03:00
nebula pre: builder packaging and beginning of C module 2026年06月25日 02:53:06 -03:00
README.md pre: builder packaging and beginning of C module 2026年06月25日 02:53:06 -03:00

Nebula

Nebula is a environment for C and Lua packages development and building.

It substitutes the manual creation and updates of makefiles for each new source also providing an intuitive way of organizing projects.

The Nebula requirements:

  • GCC or CLang compiler.
  • Lua interpreter (version >= 5.1)
  • minimal POSIX shell (for commands test and mkdir)

Installing

git clone https://codeberg.org/waxlab/nebula.git
cd nebula
./build
cp nebula $PREFIX/bin

Basic usage

This will make current directory a Nebula environment and create a basic structure for a project named planet:

nebula init planet

If planet is a Lua package, you add the package Lua scripts and C sources under the directory planet/lua.

If planet is a C library, you add the sources under planet/lib.

If planet is a C program, you add the sources containing main function under the planet/main directory.

To build the project you just:

nebula build planet

And if you created a program satellite.c under under planet/main you can run it with:

nebula run planet-satellite

Why another building tool?

For Lua you have Luarocks, for C you have make, cmake, bazel etc. but with Nebula:

  • You don't need to think about how to organize files, it provides an intuitive one that is enforced. Also, if you use other projects developed with Nebula you easily know where things are.

  • You drop new source files, think about logic, without no need to think in create makefile rules, neither which features are present between many flavors of make or shell.

  • Include directories are simple and consistent. For Lua you can write C modules that works across multiple Lua versions easily.

  • You can group many projects in one place and running them from there without need to install across the system.

  • If you want to install on system, you don't need to write complex shellscripts for this.

Keep it simple

Nebula uses Lua, Lua is one of the simplest scripting languages. So while it is intended to be simply work in 99% of the cases, you have the bonus of being written in a language easy to wrap your head around.

Nebula builds its own C module to provide the same facilities of make, install, and many shell commands all directly from Lua.

The internal Nebula cache resemble the well known Unix-like file hierarchy standard that lets you inspect files as you would do in the system installed libraries, scripts and binaries. If you know where the installed programs are, why not just make your programs build to this structure directly?

Nebula expects just a little from you: that you use a decent POSIX compliant operating system, a recent GCC/Clang compiler, a Lua interpreter and its opinionated code organization that is not to take your freedom out, but give back the simplicity to enjoy C programming, testing and tooling.