Add 64-bit installer - #7
Conversation
PeterDaveHello
left a comment
There was a problem hiding this comment.
Thanks for the contribution, please fix the indentation and checksumType, thank you.
| url64bit = 'https://github.com/transmission-remote-gui/transgui/releases/download/v5.18.0/transgui-5.18.0-setup_64bit.exe' | ||
| checksum = '07CC99294C83D2AE429033ABBDB99642F5271984966616FB2C319F087448C936' | ||
| checksum64 = 'BC625C3E32979FDDC9F30FB352843AD0AF2537F331ADDD59DD819381DF07B425' | ||
| checksumType = 'sha512' |
There was a problem hiding this comment.
I think the checksumType shouldn't be changed here
There was a problem hiding this comment.
Amended with correction. And yeah I must have changed the checksum type out of habit. I should have double-checked this better before submitting a PR.
There was a problem hiding this comment.
Feel free to send another PR after this one 👍
| $url = $download_page.links | ? href -match $re | select -Expand href -First 1 | % { 'https://github.com' + $_ } | ||
| $version = (Split-Path $url -Parent).Split("v")[1] | ||
| $url32 = $download_page.links | ? href -match $re | select -Expand href -First 1 | % { 'https://github.com' + $_ } | ||
| $version = (Split-Path $url32 -Parent).Split("v")[1] | ||
| $url64 = "https://github.com/transmission-remote-gui/transgui/releases/download/v$version/transgui-$version-setup_64bit.exe" | ||
|
|
||
| @{ | ||
| Version = $version | ||
| URL32 = $url | ||
| URL32 = $url32 |
There was a problem hiding this comment.
Can we separate change url -> url32 to another PR or another commit to keep the 64bit installer introduce minimized and focus on only 64bit related changes?
The other parts look good to me 👍
There was a problem hiding this comment.
Technically, can leave it as $url. It's somewhat of a grey area in packages I've seen as to whether or not the 32-bit url is specified as 32. Chocolatey's API seems to use -URL and -URL64(Bit) more than URL32
There was a problem hiding this comment.
Pushed an amend with that change removed.
There was a problem hiding this comment.
I agree to use "32" as part of the keyword, but just separately ;)
There was a problem hiding this comment.
If you prefer the variable naming, I'll add a second commit with it.
| $re = '\.exe$' | ||
| $url = $download_page.links | ? href -match $re | select -Expand href -First 1 | % { 'https://github.com' + $_ } | ||
| $version = (Split-Path $url -Parent).Split("v")[1] | ||
| $version = (Split-Path $url32 -Parent).Split("v")[1] |
There was a problem hiding this comment.
🤦♂️ Amending. I think I normally rely too much on the compiler to catch mistakes of that nature.
Changed $url to $url32
|
LGTM 👍 @mom1 what do you think? |
|
If there isn't any rejection, I'll merge this once our 64bit release issue was fixed, thanks for the works here. |
Adds 64-bit installer for #6