roysubs wrote: ↑April 27th, 2020, 4:43 pm
ok, bit confused as this seems to fit in 100% with everything that you said above, with only upsides for Rainmeter. I get that it's your project man, so you are the dictator in charge and that is your privilege which is absolutely your right
This bit, having "portable" as an install option but without the ability to just grab the latest portable version, is sorta frustrating as it's so easy to do. Hopefully something you can consider for the future since it's zero effort and is 100% in line with the ethos that you expressed above.
I'll shelve my project then. I guess I ain't going to be able to achieve a one-click to "grab Rainmeter portable, configure it, add a skin, and enjoy" even though portable option is already there but frustratingly denied.
Don't shelve your project yet - as I said, for every problem there is a solution. AutoHotKey and the following script (that I just used to download and install the latest Rainmeter version) will do the job. Obviously, AutoHotKey would have to be installed prior to Rainmeter (but I would recommend using a locally verified AutoHotKey install file instead of downloading the latest from the internet for this one), but it's just as easy to do (well, to be honest, even easier) than what you'd like the Rainmeter developers to do:
Code: Select all
; This script was created using Pulover's Macro Creator
; www.macrocreator.com
#NoEnv
SetWorkingDir %A_ScriptDir%
CoordMode, Mouse, Window
SendMode Input
#SingleInstance Force
SetTitleMatchMode 2
#WinActivateForce
SetControlDelay 1
SetWinDelay 0
SetKeyDelay -1
SetMouseDelay -1
SetBatchLines -1
Rainmeter:
WinHttpDownloadToFile("https://github.com/rainmeter/rainmeter/releases/download/v4.4.0.3349/Rainmeter-4.4-r3349-beta.exe", "F:\Wireless")
Sleep, 5000
Run, F:\Wireless\Rainmeter-4.4-r3349-beta.exe
Sleep, 5000
WinActivate, Rainmeter Setup ahk_class #32770
Sleep, 5000
Send, {Enter}
Sleep, 5000
Send, {Enter}
Sleep, 5000
WinActivate, Rainmeter Setup ahk_class #32770
Sleep, 5000
Send, {Enter}
Sleep, 5000
Send, {Space}
Sleep, 5000
Send, {Tab}
Sleep, 5000
Send, {Enter}
Sleep, 5000
Return
WinHttpDownloadToFile(UrlList, DestFolder)
{
UrlList := StrReplace(UrlList, "`n", ";")
UrlList := StrReplace(UrlList, ",", ";")
DestFolder := RTrim(DestFolder, "\") . "\"
Loop, Parse, UrlList, `;, %A_Space%%A_Tab%
{
Url := A_LoopField, FileName := DestFolder . RegExReplace(A_LoopField, ".*/")
whr := ComObjCreate("WinHttp.WinHttpRequest.5.1")
whr.Open("GET", Url, True)
whr.Send()
If (whr.WaitForResponse())
{
ado := ComObjCreate("ADODB.Stream")
ado.Type := 1 ; adTypeBinary
ado.Open
ado.Write(whr.ResponseBody)
ado.SaveToFile(FileName, 2)
ado.Close
}
}
}
I used Pulover's Macro Creator for all the commands above except the download and run at the start. Of course, the paths are particular to my case, so feel free to modify them. I left a 5 seconds pause / delay between each action, so that it's easy to follow what's going on. I used only keyboard captures (instead of mouse ones), as they are universal and not tied up to the resolution of the screen, the size of the windows, etc. Also, in my case, the script exists in 3 formats: .pmc (of Macro Creator), .ahk (of AutoHotKey) and .exe (exported as such from Macro Creator).
Got only two "issues" while doing the above: it didn't want to start the script and download Rainmeter at the beginning. Naturally, it was because I forgot to delete the default F3 hotkey used to start the script after running the .exe, coupled with my default restrictive firewall policy. As soon as I cleared the path, the magic began to happen...
P.S. By the way, this installs the Standard Version, not the Portable one. No need for the portable version if you already can install the standard one, is it? Of course, a single {Tab} key in the right place will choose to install the portable version, if desired.