move new_playlist Lua script from mixbus and add some garbage collection

This commit is contained in:
Nikolaus Gullotta 2018-07-17 15:16:04 -05:00
parent a54a501ad6
commit fa17364977
4 changed files with 20 additions and 2 deletions

17
scripts/new_playlist.lua Normal file
View file

@ -0,0 +1,17 @@
ardour {
["type"] = "EditorAction",
name = "New Playlist",
license = "MIT",
author = "Ardour Lua Taskforce",
description = [[Prompts and builds a new playlist for every track in the session.]]
}
function factory () return function ()
for r in Session:get_tracks():iter() do
local rtav = Editor:rtav_from_route(r) -- lookup RTAV
Editor:new_playlists(rtav:to_timeaxisview())
end
collectgarbage()
end end