Skip to content

Instantly share code, notes, and snippets.

@tkuchiki
Created November 5, 2013 07:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tkuchiki/7315374 to your computer and use it in GitHub Desktop.
Save tkuchiki/7315374 to your computer and use it in GitHub Desktop.
lua で 外部コマンドの実行結果を受け取る
# http://stackoverflow.com/questions/9676113/lua-os-execute-return-value
local handle = io.popen("ls")
local result = handle:read("*a")
handle:close()
print(result)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment