mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-07 07:14:56 +01:00
Also move Lua scripts to share subfolder
This commit is contained in:
parent
bf649cd68a
commit
180843f9bd
129 changed files with 2 additions and 2 deletions
20
share/scripts/_system_exec.lua
Normal file
20
share/scripts/_system_exec.lua
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
ardour { ["type"] = "EditorAction", name = "System Exec" }
|
||||
|
||||
function factory () return function ()
|
||||
-- ** EXAMPLES TO RUN EXTERNAL APPLICATIONS ** --
|
||||
|
||||
-- run a command in a shell and wait for it to complete.
|
||||
--
|
||||
-- Details: basically just system(3), except on Unix like systems with
|
||||
-- memory-locking, this call is special-cased to use vfork and close
|
||||
-- file-descriptors. On other systems it defaults to Lua's os-library
|
||||
-- built-in os.execute system() call.
|
||||
os.execute ("date > /tmp/testdate")
|
||||
|
||||
-- os.forkexec() works as fire-and-forget. execv(3) style
|
||||
--
|
||||
-- Details: It calls vfork() and exec() under the hood, passing each
|
||||
-- argument separately to exec (and needs a full-path to the binary).
|
||||
os.forkexec ("/usr/bin/xterm")
|
||||
os.forkexec ("/bin/sh", "-c", "import --frame \"/tmp/scr_$(date).png\"")
|
||||
end end
|
||||
Loading…
Add table
Add a link
Reference in a new issue