Old 10-01-2020, 03:33 AM   #1
FeedTheCat
Human being with feelings
 
FeedTheCat's Avatar
 
Join Date: May 2019
Location: Berlin
Posts: 1,548
Default REAPER Update Utility

A simple utility that automates the REAPER update/installation process.

Compatible with Windows/MacOS/Linux & portable installs

Note: On MacOS 10.15+ you might have to give full disk access permission to REAPER and the terminal application

Features:
  • Update REAPER to the latest version
  • Install old versions of REAPER
  • Get notifications for new releases (enable them under Menu > Startup notifications > Run script on startup)
  • Open changelog in web browser (links to forum thread if available)
  • Post-installation script hooks for advanced users (more info here)




You can find the script on my github or download it using ReaPack:
Copy and paste this link into: Extensions > ReaPack > Import a repository
Code:
https://raw.githubusercontent.com/iliaspoulakis/Reaper-Tools/master/index.xml
Donation Link

Last edited by FeedTheCat; 01-10-2022 at 09:57 AM.
FeedTheCat is offline   Reply With Quote
Old 10-01-2020, 03:37 AM   #2
Coachz
Human being with feelings
 
Coachz's Avatar
 
Join Date: Oct 2010
Location: Charleston, SC
Posts: 11,097
Default

That's a winner. Way to go!
Coachz is offline   Reply With Quote
Old 10-01-2020, 04:44 AM   #3
b0se
Human being with feelings
 
b0se's Avatar
 
Join Date: Jan 2019
Location: UK
Posts: 938
Default

Very cool :¬)
__________________
Smooth V6 1080P/HiDPI Theme
b0se is offline   Reply With Quote
Old 10-01-2020, 06:22 AM   #4
uksnowy
Human being with feelings
 
uksnowy's Avatar
 
Join Date: Feb 2008
Location: 6950 DK
Posts: 635
Default

Ok, Im confused.. Reaper automatically tells me when there are updates available. Why do I need this? Does it bring something extra?
__________________
REAPING HAVOC SINCE 2008
uksnowy is offline   Reply With Quote
Old 10-01-2020, 06:31 AM   #5
Meo-Ada Mespotine
Human being with feelings
 
Meo-Ada Mespotine's Avatar
 
Join Date: May 2017
Location: Leipzig
Posts: 6,015
Default

Auto install included.
And devs releases can be installed too.
__________________
Use you/she/her.Ultraschall-Api Lua Api4Reaper
Bugreports&Docs notes please do here:https://github.com/Ultraschall/ultra...-reaper/issues - Donate, if you wish
Meo-Ada Mespotine is offline   Reply With Quote
Old 10-01-2020, 06:38 AM   #6
nofish
Human being with feelings
 
nofish's Avatar
 
Join Date: Oct 2007
Location: home is where the heart is
Posts: 11,701
Default

Does it work with portable installs?
nofish is offline   Reply With Quote
Old 10-01-2020, 06:53 AM   #7
Ozman
Human being with feelings
 
Join Date: Feb 2015
Posts: 697
Default

Awe, man...
This is cool.

I think it would be cool to also either have links to the change logs or something to show the user changes in the new builds.
Ozman is offline   Reply With Quote
Old 10-01-2020, 06:56 AM   #8
todoublez
Human being with feelings
 
todoublez's Avatar
 
Join Date: Aug 2019
Location: beijing
Posts: 582
Default

Does it work on mac ?
__________________
Reaper 6.55 / SWS/S&M: v2.11.0 / Hackintosh OSX Catalina 10.15.7
i9 9900KS / 8 Cores base:4.0Ghz turbo:5.0Ghz / 64G RAM /
JS_ReaScriptAPI: v1.215 / Ultraschall API: v43220.00
todoublez is offline   Reply With Quote
Old 10-01-2020, 07:10 AM   #9
X-Raym
Human being with feelings
 
X-Raym's Avatar
 
Join Date: Apr 2013
Location: France
Posts: 9,103
Default

This looks very nice !! Thx !


Ill try it as Sartup action

Last edited by X-Raym; 10-01-2020 at 07:15 AM.
X-Raym is offline   Reply With Quote
Old 10-01-2020, 07:43 AM   #10
FeedTheCat
Human being with feelings
 
FeedTheCat's Avatar
 
Join Date: May 2019
Location: Berlin
Posts: 1,548
Default

Quote:
Originally Posted by nofish View Post
Does it work with portable installs?
I tested it on a Windows portable install and it seemed to work just fine.

Quote:
Originally Posted by Ozman View Post
I think it would be cool to also either have links to the change logs or something to show the user changes in the new builds.
That would be cool! I might add that...

Quote:
Originally Posted by todoublez View Post
Does it work on mac ?
No (not yet), I don't have a mac so I can't test it atm. I hope it's not hard to add.

Quote:
Originally Posted by X-Raym View Post
Ill try it as Sartup action
Great idea! Hadn't thought about that at all. I guess the script could check if it is being used as a startup action and then only show the GUI if there's actually an update available.
FeedTheCat is offline   Reply With Quote
Old 10-01-2020, 08:16 AM   #11
X-Raym
Human being with feelings
 
X-Raym's Avatar
 
Join Date: Apr 2013
Location: France
Posts: 9,103
Default

Quote:
. I guess the script could check if it is being used as a startup action and then only show the GUI if there's actually an update available.

The trick would be for the script to not launched any GUI if there isn't any update available.


You can have a second action for that, and still have one whcih display the GUI no matter what. Code can be share across scripts.

(maybe for this new action, a checkbox 'dismiss this update' could be made so that it doesnt propose several time the same update until a new one is come).
X-Raym is offline   Reply With Quote
Old 10-01-2020, 08:53 AM   #12
Vagelis
Human being with feelings
 
Vagelis's Avatar
 
Join Date: Oct 2017
Location: Larisa, Greece
Posts: 2,731
Default

Very cool, thanks!
Vagelis is online now   Reply With Quote
Old 10-01-2020, 09:30 AM   #13
Klangfarben
Human being with feelings
 
Join Date: Jul 2016
Location: Los Angeles, CA
Posts: 1,647
Default

So good.
Klangfarben is offline   Reply With Quote
Old 10-01-2020, 10:39 AM   #14
Coachz
Human being with feelings
 
Coachz's Avatar
 
Join Date: Oct 2010
Location: Charleston, SC
Posts: 11,097
Default

This works great. Way to go.
Coachz is offline   Reply With Quote
Old 10-01-2020, 02:18 PM   #15
RobinGShore
Human being with feelings
 
Join Date: May 2013
Location: New York
Posts: 757
Default

Wow this looks great, hope we can get a version that works on mac at some point.
RobinGShore is offline   Reply With Quote
Old 10-01-2020, 03:16 PM   #16
Jae.Thomas
Human being with feelings
 
Join Date: Jun 2006
Posts: 22,322
Default

yeah looks really neat thank you!!!
__________________
My Band and Solo/originals - The Secret Reasons
REAPER - B.D.E. (big dev energy)
Jae.Thomas is offline   Reply With Quote
Old 10-01-2020, 03:42 PM   #17
Jae.Thomas
Human being with feelings
 
Join Date: Jun 2006
Posts: 22,322
Default

doesn't work for me, I think it's cause I have reaper installed in a portable way.
__________________
My Band and Solo/originals - The Secret Reasons
REAPER - B.D.E. (big dev energy)
Jae.Thomas is offline   Reply With Quote
Old 10-01-2020, 05:28 PM   #18
FeedTheCat
Human being with feelings
 
FeedTheCat's Avatar
 
Join Date: May 2019
Location: Berlin
Posts: 1,548
Default

Quote:
Originally Posted by Jae.Thomas View Post
doesn't work for me, I think it's cause I have reaper installed in a portable way.
It should work just fine on portable installs. Some additional info would be really useful, like:
Are you using Windows?
Does the script crash somewhere?
Does it say it's installing but it restarts with the same version?
FeedTheCat is offline   Reply With Quote
Old 10-01-2020, 06:31 PM   #19
Meo-Ada Mespotine
Human being with feelings
 
Meo-Ada Mespotine's Avatar
 
Join Date: May 2017
Location: Leipzig
Posts: 6,015
Default

Quote:
Originally Posted by RobinGShore View Post
Wow this looks great, hope we can get a version that works on mac at some point.
Theoretically this should be possible. I once had the same idea for such an update-script and looked into the possibility to install Reaper64.App from a dmg.
It's possible to mount a dmg via terminal, so copying the app from there to the correct location should be possible.
Only problem I could see are potential privilege-problems, especially on Catalina and later, that could prevent that.

I've never actually tested it out, I was still researching it theoretically, though.

@FeedTheCat
What do you use for downloading the file? Curl on Linux probably? What do you use on Windows? I experimented back then with certutil so I could be compatible with Windows 7 as well but never actually finished the stuff.
__________________
Use you/she/her.Ultraschall-Api Lua Api4Reaper
Bugreports&Docs notes please do here:https://github.com/Ultraschall/ultra...-reaper/issues - Donate, if you wish
Meo-Ada Mespotine is offline   Reply With Quote
Old 10-01-2020, 10:42 PM   #20
cool
Human being with feelings
 
Join Date: Dec 2017
Location: Sunny Siberian Islands
Posts: 730
Default

Awesome! It is curious that such an old idea has only now been implemented. This has been enough for a long time
cool is online now   Reply With Quote
Old 10-02-2020, 01:57 AM   #21
FeedTheCat
Human being with feelings
 
FeedTheCat's Avatar
 
Join Date: May 2019
Location: Berlin
Posts: 1,548
Default

Quote:
Originally Posted by Meo-Ada Mespotine View Post
Theoretically this should be possible. I once had the same idea for such an update-script and looked into the possibility to install Reaper64.App from a dmg.
It's possible to mount a dmg via terminal, so copying the app from there to the correct location should be possible.
Only problem I could see are potential privilege-problems, especially on Catalina and later, that could prevent that.

I've never actually tested it out, I was still researching it theoretically, though.
That's about where I'm at as well. And I haven't found out yet if it's even possible to run the reaper .dmg file in a silent "NO-GUI" mode. Would also be a bummer.

Quote:
Originally Posted by Meo-Ada Mespotine View Post
@FeedTheCat
What do you use for downloading the file? Curl on Linux probably? What do you use on Windows? I experimented back then with certutil so I could be compatible with Windows 7 as well but never actually finished the stuff.
I wrote the script for Linux initially so I used curl. Didn't even cross my mind that Windows 7 doesn't have that :S I guess I'll boot up a VM and try out certutil. Thx for the tip Meo!
FeedTheCat is offline   Reply With Quote
Old 10-02-2020, 02:26 AM   #22
X-Raym
Human being with feelings
 
X-Raym's Avatar
 
Join Date: Apr 2013
Location: France
Posts: 9,103
Default

CURL CLI can be packed with the script if needed : https://curl.haxx.se/
X-Raym is offline   Reply With Quote
Old 10-02-2020, 10:15 AM   #23
Jae.Thomas
Human being with feelings
 
Join Date: Jun 2006
Posts: 22,322
Default

Quote:
Originally Posted by FeedTheCat View Post
It should work just fine on portable installs. Some additional info would be really useful, like:
Are you using Windows?
Does the script crash somewhere?
Does it say it's installing but it restarts with the same version?
windows 10
no script crash as far as I can tell
it says it is intalling and will restart but no update version
__________________
My Band and Solo/originals - The Secret Reasons
REAPER - B.D.E. (big dev energy)
Jae.Thomas is offline   Reply With Quote
Old 10-02-2020, 10:31 AM   #24
Tobbe
Human being with feelings
 
Tobbe's Avatar
 
Join Date: Sep 2009
Location: Up North somewhere
Posts: 679
Default

Worked flawless on Linux Mint 20...no problemo

Thanks
__________________
OS: Manjaro KDE Plasma, Reaper For Linux (64Bit) native linux-vst plugins, LSP-Plugins, TpL-Plugins, Harrison's AVA & VST Plugins. Behringer U-PHORIA UMC22.
Tobbe is online now   Reply With Quote
Old 10-02-2020, 01:57 PM   #25
FeedTheCat
Human being with feelings
 
FeedTheCat's Avatar
 
Join Date: May 2019
Location: Berlin
Posts: 1,548
Default

Quote:
Originally Posted by X-Raym View Post
CURL CLI can be packed with the script if needed : https://curl.haxx.se/
Wouldn't you have to include a different binary for each OS-type and processor architecture?

Quote:
Originally Posted by Jae.Thomas View Post
windows 10
no script crash as far as I can tell
it says it is intalling and will restart but no update version
Are you using the latest version? I can't reproduce it. I just tested it on a portable x32 and x64 Windows 10 install, and it worked on both.

Quote:
Originally Posted by Tobbe View Post
Worked flawless on Linux Mint 20...no problemo
Thanks
Glad it's working on Mint! Thanks for reporting
FeedTheCat is offline   Reply With Quote
Old 10-02-2020, 02:16 PM   #26
FeedTheCat
Human being with feelings
 
FeedTheCat's Avatar
 
Join Date: May 2019
Location: Berlin
Posts: 1,548
Default Update

I added 2 features since the first release:
  • Reaper should now automagically restart once the update went through
  • Startup Mode (experimental):
    Inside the script there's a variable called startup_mode. Set this to true if you're using the script inside/as a global startup action. This will change how the script behaves on startup, the GUI will only show when there's a new (unseen) update available.
    The variable does not exist anymore, simply use the script as a startup action

Last edited by FeedTheCat; 10-14-2020 at 01:55 PM.
FeedTheCat is offline   Reply With Quote
Old 10-02-2020, 02:32 PM   #27
Meo-Ada Mespotine
Human being with feelings
 
Meo-Ada Mespotine's Avatar
 
Join Date: May 2017
Location: Leipzig
Posts: 6,015
Default

You might want to set the entry for update-check in the reaper.ini as well to off:

Code:
[REAPER]
verchk=0
as otherwise, Reaper's own update-check might mess up your script, when a new version is released.


Edit:

And here's my experimental download-function that uses certutil to download a file. In this example, the Reaper-logo from the Reaper-site:

Code:
function DownloadFile(fileurl, target)
  -- certutil
  Filename=fileurl:match(".*/(.*)")
  if reaper.GetOS()=="Win32" or reaper.GetOS()=="Win64" then
    os.execute("certutil -urlcache -f \""..fileurl.."\" \""..target.."/"..Filename.."\" >NIL")
  end
end

DownloadFile("http://reaper.fm/v5img/logo.jpg", "c:\\")
It's not finalized and polished but should give you something to work with on Windows 7.
__________________
Use you/she/her.Ultraschall-Api Lua Api4Reaper
Bugreports&Docs notes please do here:https://github.com/Ultraschall/ultra...-reaper/issues - Donate, if you wish

Last edited by Meo-Ada Mespotine; 10-02-2020 at 02:37 PM.
Meo-Ada Mespotine is offline   Reply With Quote
Old 10-02-2020, 04:42 PM   #28
X-Raym
Human being with feelings
 
X-Raym's Avatar
 
Join Date: Apr 2013
Location: France
Posts: 9,103
Default

Code:
Wouldn't you have to include a different binary for each OS-type and processor arch
Not an issue for reapack,
or you can ask user to download it by themsleves (but packing curl is probably more user friendly).


That said is there other native way (like mespotine is showing us) it is even better.
X-Raym is offline   Reply With Quote
Old 10-03-2020, 06:04 AM   #29
X-Raym
Human being with feelings
 
X-Raym's Avatar
 
Join Date: Apr 2013
Location: France
Posts: 9,103
Default

Quote:
Inside the script there's a variable called startup_mode. Set this to true if you're using the script inside/as a global startup action. This will change how the script behaves on startup, the GUI will only show when there's a new (unseen) update available.
To not lose this setting at each script update,
the best is to share a companion script with a simple dofile() to the original script,
and the variable already set to false.


THis si the system I used in my Presets scripts, which allows users to toggle init variables without modiyinf the script.


It requires wrapping the main function of the script inside a Init() function, so that the Init function can be run from the preset script after having changed the desired variables.


https://gist.github.com/X-Raym/f7f63...bb3b81aff0b744


A script like that could be pakc right into your pack for easy distribution. :P
X-Raym is offline   Reply With Quote
Old 10-05-2020, 02:25 AM   #30
lb0
Human being with feelings
 
Join Date: Apr 2014
Posts: 4,147
Default

So good!! - thank you!
__________________
Projects - Reascripts - Lua:
Smart Knobs 2 | LBX Stripper | LBX Floating FX Positioner
Donate via Paypal | LBX Tools Website
lb0 is offline   Reply With Quote
Old 10-05-2020, 08:14 AM   #31
nofish
Human being with feelings
 
nofish's Avatar
 
Join Date: Oct 2007
Location: home is where the heart is
Posts: 11,701
Default

Hi FeedTheCat,

I just gave it a try but get this:

I'm quite sure my internet connection is working because immediately before running the script I installed it via RePack which worked fine.
Any idea what could be wrong?
Win 8.1/x64, R6.14+dev0925/x64

Thanks.
nofish is offline   Reply With Quote
Old 10-05-2020, 06:30 PM   #32
FeedTheCat
Human being with feelings
 
FeedTheCat's Avatar
 
Join Date: May 2019
Location: Berlin
Posts: 1,548
Default

Quote:
Originally Posted by nofish View Post
Any idea what could be wrong?
Win 8.1/x64, R6.14+dev0925/x64

Thanks.
Hi nofish, I think it's because you are on Win 8, I had previously only tested it on Win 10. I'll push an update tomorrow that should make the script compatible with Windows 7 and updwards. Thx for trying it out

Last edited by FeedTheCat; 10-06-2020 at 12:24 PM.
FeedTheCat is offline   Reply With Quote
Old 10-06-2020, 04:52 AM   #33
Stevie
Human being with feelings
 
Stevie's Avatar
 
Join Date: Feb 2015
Location: Urkrain, Russia
Posts: 246
Default

bravo
__________________
Spotify
Stevie is offline   Reply With Quote
Old 10-06-2020, 10:27 AM   #34
Jae.Thomas
Human being with feelings
 
Join Date: Jun 2006
Posts: 22,322
Default

I think this is a good idea, maybe even just a setting in an external file?

is this right?

Code:
-------------------------------- USER CONFIGURATION --------------------------------

-- Startup mode: Show GUI when updates are available (first script run only)
local startup_mode = true

-- Show GUI for new pre-release versions
local startup_check_dev_releases = true

------------------------------------------------------------------------------------
Quote:
Originally Posted by X-Raym View Post
To not lose this setting at each script update,
the best is to share a companion script with a simple dofile() to the original script,
and the variable already set to false.


THis si the system I used in my Presets scripts, which allows users to toggle init variables without modiyinf the script.


It requires wrapping the main function of the script inside a Init() function, so that the Init function can be run from the preset script after having changed the desired variables.


https://gist.github.com/X-Raym/f7f63...bb3b81aff0b744


A script like that could be pakc right into your pack for easy distribution. :P
__________________
My Band and Solo/originals - The Secret Reasons
REAPER - B.D.E. (big dev energy)
Jae.Thomas is offline   Reply With Quote
Old 10-06-2020, 12:39 PM   #35
FeedTheCat
Human being with feelings
 
FeedTheCat's Avatar
 
Join Date: May 2019
Location: Berlin
Posts: 1,548
Default

Quote:
Originally Posted by Jae.Thomas View Post
I think this is a good idea, maybe even just a setting in an external file?

is this right?
These would be correct yes, but I just removed them in the new update
The script should now auto-detect if it is run as a startup action and behave accordingly (silently exit if there's no updates). This should keep everything nice and simple on the user end of things.

Btw, does the script still not work on your end? There's now a debugging output you can enable inside the script (Exactly like you did with these variables). If you send me the output I might be able to figure out what's wrong.

To the scripters in this thread:
Can somebody think of a reliable method to determine whether a script is used in the context of a global startup action? My solution works, but it's kind of yuck...
FeedTheCat is offline   Reply With Quote
Old 10-06-2020, 12:51 PM   #36
FeedTheCat
Human being with feelings
 
FeedTheCat's Avatar
 
Join Date: May 2019
Location: Berlin
Posts: 1,548
Default Update v1.2

New features
  • Support for older Windows versions (7 and higher)
  • The script auto-detects if it used as/within a global startup action. It will silently check for updates and notify when a new version is available.
  • Added debugging output: Enable this by setting 'debug = true' in the script header.
  • Added links that will open the latest changelog in a web-browser
Things to come
  • OSX support
  • Make changelog links open forum thread instead (if it can be found).
  • Support for RC Versions
FeedTheCat is offline   Reply With Quote
Old 10-06-2020, 01:29 PM   #37
Jae.Thomas
Human being with feelings
 
Join Date: Jun 2006
Posts: 22,322
Default

no, not quite yet.

it says its downloading, I get the prompt from windows to allow it, and then restarts with the old version.

Also, will it trigger a notification if I am behind on dev/rc builds?
__________________
My Band and Solo/originals - The Secret Reasons
REAPER - B.D.E. (big dev energy)
Jae.Thomas is offline   Reply With Quote
Old 10-06-2020, 02:15 PM   #38
X-Raym
Human being with feelings
 
X-Raym's Avatar
 
Join Date: Apr 2013
Location: France
Posts: 9,103
Default

Quote:
To the scripters in this thread:
Can somebody think of a reliable method to determine whether a script is used in the context of a global startup action? My solution works, but it's kind of yuck...
I don't think this is the way to handle this. It is overcomplicated.


A simple side action to run the script main check in background if the core functions are run externaly (a simple boolean variable check) would be more easily and more reliable, as there is several ways to have startup actions (__start.lua scripts, SWS global startup, SWS global startup with custom actions etc).



Thank for your update and work on this anyway :P
X-Raym is offline   Reply With Quote
Old 10-06-2020, 02:29 PM   #39
FeedTheCat
Human being with feelings
 
FeedTheCat's Avatar
 
Join Date: May 2019
Location: Berlin
Posts: 1,548
Default

Quote:
Originally Posted by Jae.Thomas View Post
no, not quite yet.

it says its downloading, I get the prompt from windows to allow it, and then restarts with the old version.

Also, will it trigger a notification if I am behind on dev/rc builds?
When the script is run as/inside a global startup action, it will notify you ONCE when a new Reaper version is published (release/pre-release/RC). You can then choose to install or just go through the changelog (or dismiss the dialog)

Seems like the issue on your end is that it's installing reaper in the wrong location. Which is kind of weird since it should install it where your reaper.exe is located (API: reaper.GetExePath). I'm using this so that it always updates the running Reaper, but maybe I'm missing something here.
FeedTheCat is offline   Reply With Quote
Old 10-06-2020, 02:51 PM   #40
FeedTheCat
Human being with feelings
 
FeedTheCat's Avatar
 
Join Date: May 2019
Location: Berlin
Posts: 1,548
Default

Quote:
Originally Posted by X-Raym View Post
I don't think this is the way to handle this. It is overcomplicated.
Agreed, I get your point. And this only kind of makes sense with this specific script as I'm doing OS-dependent terminal stuff anyway. It should work for __startup.lua and SWS all the same though. I'm still hoping to find a generic "clean" solution that can be used in other scripts as well (I had another script where I wanted to know whether it's run on startup)
FeedTheCat is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 02:50 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.