#Requires AutoHotkey v2.0 #SingleInstance Force ; Automation Agent Quick Timeline Actions ; https://docs.mamoworld.com/automation-agent/getting-started/keyboard-shortcuts-and-remote-triggers ; ; Most users do not need to change this number. If Remote Execution links copied ; on your computer start with port 53126 or 53127, enter that number here. AutomationAgentPort := 53125 ; Make the shortcuts available in both Premiere Pro and Premiere Pro (Beta). GroupAdd("AdobePremiere", "ahk_exe Adobe Premiere Pro.exe") GroupAdd("AdobePremiere", "ahk_exe Adobe Premiere Pro (Beta).exe") RunAutomationAgentTool(toolId) { global AutomationAgentPort url := Format( "http://127.0.0.1:{1}/automation/run-library-entry?sourceId=official&toolId={2}", AutomationAgentPort, toolId ) RunAutomationAgentUrl(url) } RunAutomationAgentUrl(url) { ; Keep the preset ready when you press several shortcuts quickly. command := Format( 'curl.exe --silent --show-error --fail --max-time 3600 "{1}"', url ) try Run(command, , "Hide") catch Error as err MsgBox( "Automation Agent could not start the request.`n`n" . err.Message, "Automation Agent" ) } ; These shortcuts work only while Premiere Pro or Premiere Pro (Beta) is the ; active app. If a shortcut overlaps, only the Automation Agent action runs. #HotIf WinActive("ahk_group AdobePremiere") ; Comparison lanes: Ctrl + Alt + Shift + 1 through 5 ^!+1::RunAutomationAgentTool("recipe-quick-timeline-activate-comparison-lane-1") ^!+2::RunAutomationAgentTool("recipe-quick-timeline-activate-comparison-lane-2") ^!+3::RunAutomationAgentTool("recipe-quick-timeline-activate-comparison-lane-3") ^!+4::RunAutomationAgentTool("recipe-quick-timeline-activate-comparison-lane-4") ^!+5::RunAutomationAgentTool("recipe-quick-timeline-activate-comparison-lane-5") ; Cycle comparison lanes and restore all tracks ^!+Left::RunAutomationAgentTool("recipe-quick-timeline-solo-previous-video-audio-tracks") ^!+Right::RunAutomationAgentTool("recipe-quick-timeline-solo-next-video-audio-tracks") ^!+0::RunAutomationAgentTool("recipe-quick-timeline-unsolo-all-video-audio-tracks") ; Selected clips and their tracks ^!+s::RunAutomationAgentTool("recipe-quick-timeline-solo-tracks-containing-selected-clips") ^!+d::RunAutomationAgentTool("recipe-quick-timeline-disable-selected-clips") ^!+e::RunAutomationAgentTool("recipe-quick-timeline-enable-selected-clips") ^!+a::RunAutomationAgentTool("recipe-quick-timeline-select-all-disabled-clips") ; Add shortcuts for any other saved Automation Agent script here. Copy its ; Remote Execution URL in the Library, remove the leading semicolon below, ; choose an unused hotkey, and paste the URL between the quotation marks. ; ; Modifier symbols: ^ = Ctrl, ! = Alt, + = Shift, # = Windows key. ; Common key names: Space, Enter, Tab, Esc, Left, Right, Up, Down, and F1-F24. ; Write letters and top-row numbers directly, for example k or 7. ; Everything before :: is the shortcut; everything after :: is the action. ; A line beginning with ; is a disabled comment. Remove the first ; from the ; example shortcut line to enable it. ; ; This example binds the pasted URL to Ctrl + Alt + Shift + F11: ; ^!+F11::RunAutomationAgentUrl("PASTE_REMOTE_EXECUTION_URL_HERE") #HotIf