1 download 12 views Aug 31, 2026
profile

Lua Linker by RedTech0

project thumbnail

Lua Linker

this is a file that allows you to turn a project (aka many small files which have 'require' that chain to assemble the project) into one file. This concept is taken form languages like C where you have a linker as part of the compiler

instructions

include (require)

to do a "require" you simply type
--#include [relative path]
into the Lua file at any position

[relative path] here means the way to get to the file form this file

Note that the import will not be put where the comment is but above the file importing it

output

the output is the base file given to the linker with all it's dependencies and their dependencies stitched on top.
the linker dynamically resolves where what should be and compacts the file down (removes comments not needed spaces and tabs)

warning

this does physically graft the files together so local variables with the same name may override each other in the final product

Config

you can configure a few things abt the linker in the top of the file such as:

  • LH_AUTO_SAVE_INTERVALS: how many lines it should write before saving in between while compacting files
  • TABS: how many spaces are seen as a tab key press (since code editors do their own thing)
  • FUTURE FEATURES

  • UI: a use that makes navigation easier
  • more instructions like "--#if" which also utilize arguments or an environment
  • 	
    	
    	wget run https://pinestore.cc/d/265
    	
    
    Download Git Repository
    project screenshot project screenshot
    comments
    You can login with Discord to leave comments and reply to others!
    pfp RedTech0 Creator 5 hours ago

    if you are wondering why this looks so haste fully made, then i have to tell you that it is because originally this was a tool i programmed for another project where had a lot of require calls for which i iterated over potential solutions to make it more robust and then settled on the idea of a C style linker (i also never planned to upload it to the public but it seems as if there aren't a lot of tools like this out there)