-
Notifications
You must be signed in to change notification settings - Fork 21
os.get
mba105 edited this page Sep 24, 2014
·
2 revisions
Home > [Scripting Reference](Scripting Reference) > os.get
The os.get function identifies the currently targeted operating system.
#!lua
id = os.get()
None.
An operating system identifier, one of bsd, linux, macosx, solaris, or windows.
Note that this function returns the OS being targeted, which is not necessarily the same as the OS on which Premake is being run. If you are running on Mac OS X and generating Visual Studio project files, the identifier is "Windows", since that is the OS being targeted by the Visual Studio action.
#!lua
if os.get() == "windows" then
-- do something Windows-specific
end