How to use premake on *.lua files

2.2k Views Asked by At

How do I use premake4? I have a .lua file that I want to compile.

I downloaded the executable premake4 but when I run ./premake4 myfile it gives me an error.

1

There are 1 best solutions below

0
On

Normally, Premake4 expects to execute a script called premake4.lua. You are strongly advised to hold to this convention.

However, if you absolutely must use a different file, you can call premake4 --file=<insert file here>. But again, you are advised to just use standard Premake conventions.

Note that this is all spelled out in Premake's documentation. Even the command-line help will tell you how to use the --file switch.