Skip to content

Instantly share code, notes, and snippets.

@dupontgu
Last active July 6, 2021 13:44
Show Gist options
  • Save dupontgu/e3ae585406d4ba48164eafd3b7d279ad to your computer and use it in GitHub Desktop.
Save dupontgu/e3ae585406d4ba48164eafd3b7d279ad to your computer and use it in GitHub Desktop.
ReaScript that triggers actions on IFTTT based on when you start and stop recording in Reaper
turnLightOn = "/bin/sh -c \"curl -H 'Connection: close' -i -X POST 'https://maker.ifttt.com/trigger/record_lamp_on/with/key/your_key_here'\"";
turnLightOff = "/bin/sh -c \"curl -H 'Connection: close' -i -X POST 'https://maker.ifttt.com/trigger/record_lamp_off/with/key/your_key_here'\"";
lastState = 0;
function main()
(
currentState = GetPlayState() & 4;
lastState != currentState ? (
command = currentState > 0 ? turnLightOn : turnLightOff;
ExecProcess(#result, command, 0);
lastState = currentState;
);
defer("main();");
);
main();
@Lowice
Copy link

Lowice commented Jul 6, 2021

Oke , well there is an js script editor in logic ,. so I thought is would be possible , I hope that maybe you can help me out ! ,. thank anyway for your reply !
Greetz !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment