|
Hi, I was looking for a way to get the OS name and architecture in pure lua, without depending on other modules. I could not find anything satisfactory so I just put up a small project on GitHub to do that. I am posting here for feedback and in case it might be useful to somebody else. On Windows, the program will use environment variables. On
linux-like OS, it will use uname with popen. Example on Windows:
Example on MacOs X:
Example on Linux:
It is heavily based on the following Gist: https://gist.github.com/soulik/82e9d02a818ce12498d1 The project page : https://github.com/bluebird75/lua_get_os_name What would be really nice is to fetch the actual windows version. If you have some ideas.... Cheers, Philippe
|