Skip to content

Instantly share code, notes, and snippets.

@tmathews
Last active June 11, 2024 22:23
Show Gist options
  • Save tmathews/846fe627bbf403a90a9331366c5bd498 to your computer and use it in GitHub Desktop.
Save tmathews/846fe627bbf403a90a9331366c5bd498 to your computer and use it in GitHub Desktop.
---@meta
---@class premake
premake = {}
---@class io
io = {}
function io.readfile(filename) end
---@param filename string
---@param buffer string
function io.writefile(filename, buffer) end
---@class os
os = {}
function os.execute(command) end
function os.executef(command, args, ...) end
---@param path string
function os.mkdir(path) end
---@param path string
function os.rmdir(path) end
---@param str string
function os.getenv(str) end
---@class string
string = {}
function string.explode(str, separator) end
---@class path
path = {}
function path.getbasename(path) end
---Joins two path portions together into a single path.
---@param a string
---@param b string
---@param ... string
---@return string
function path.join(a, b, ...) end
---Returns the absolute file path.
---@param path string
---@return string
function path.getabsolute(path) end
---The path.getrelative function computes a relative path from one directory to
---another.
---@param src string
---@param dst string
---@return string
function path.getrelative(src, dst) end
---@param path string
---@return string
function path.getbasename(path) end
---@type table
_OPTIONS = {}
---@type table
_ARGS = {}
---* Formatted print to stdout.
function printf(...) end
---* Include a premake lua file.
function include(filename) end
function includedirs(arr) end
function libdirs(arr) end
function postbuildcommands(arr) end
---@param type string
function architecture(type) end
function links(arr) end
function defines(arr) end
function filter(arr) end
function project(name) end
---Define a new workspace.
---@param name string
function workspace(name) end
function kind(name) end
function dpiawareness(type) end
function debugdir(path) end
function targetdir(path) end
function files(arr) end
function removefiles(arr) end
function startproject(name) end
function configurations(arr) end
function cppdialect(type) end
function location(path) end
function language(type) end
function platforms(arr) end
function newoption(table) end
function newaction(table) end
function rtti(value) end
function symbols(value) end
function buildoptions(arr) end
function linkoptions(arr) end
function project() end
function objdir(path) end
function targetsuffix(str) end
function omitframepointer(type) end
function runtime(type) end
function editandcontinue(type) end
function optimize(type) end
function vectorextensions(type) end
function characterset(type) end
function nativewchar(type) end
function systemversion(version) end
function exceptionhandling(type) end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment