Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build release packages for Chocolatey #477

Closed
RAYs3T opened this issue Jan 10, 2022 · 9 comments
Closed

Build release packages for Chocolatey #477

RAYs3T opened this issue Jan 10, 2022 · 9 comments
Labels

Comments

@RAYs3T
Copy link

RAYs3T commented Jan 10, 2022

As currently no (secure) auto update for windows is possible, adding support for https://chocolatey.org/ would be awesome.

Quick information on what Chocolatey is

It's a package manager for windows. You can compare it to apt on Ubuntu.

You can basically install a package with a powershell command for example: choco install electronmail
And if you want to update a package you can just run choco upgrade pkgname.

Benefits

  • Upgrading is more secure, as choco is verifying the Hash after download.
  • More comfortable (as the user has just to run a command, instead of downloading a new .exe)
  • And this might even attract new users who just search in the packages of choco for something like this.
@vladimiry
Copy link
Owner

The electronmail name is already taken by someone and the package is not being updated. So I've pushed https://community.chocolatey.org/packages/electron-mail package which is currently being validated by the chocolatey platform. They say that validation takes 1-3 days.

@RAYs3T
Copy link
Author

RAYs3T commented Jan 10, 2022

Awesome!
I'll set me a reminder and test once the package is available.

@RAYs3T
Copy link
Author

RAYs3T commented Jan 14, 2022

It's still in pending review, but installing it with a specified version works so far.

@vladimiry
Copy link
Owner

vladimiry commented Jan 14, 2022

works so far

There is no fancy stuff by the way. Just a run of the "exe" package from https://github.com/vladimiry/ElectronMail/releases with /S flag (silent installing mode).

tools\chocolateyinstall.ps1:

$ErrorActionPreference = 'Stop'

if ((Get-OSArchitectureWidth 32) -or $env:ChocolateyForceX86) {
  throw ("This application currently only supports 64-bit Windows systems.")
}

$packageArgs = @{
  url64         = 'https://github.com/vladimiry/ElectronMail/releases/download/v4.13.2/electron-mail-4.13.2-windows-x64-nsis-installer.exe'
  checksum64    = '5c6c6bce6967a4e43ac1ffaa5692a5cdb3b85fe5f616654b978d115147399d29'
  checksumType  = 'sha256'
  softwareName  = 'ElectronMail*'
  fileType      = 'exe'
  silentArgs    = "/S"
  validExitCodes= @(0)
  packageName   = $env:ChocolateyPackageName
}

Install-ChocolateyPackage @packageArgs

It also installs vcredist140 from chocolatey so the respective installing process defined in ./scripts/electron-builder/installer.nsh doesn't get triggered during installing process as the process will be stuck then. See dependency section in electron-mail.nuspec from electron-mail.4.13.2.nupkg (this file needs to be unpacked as a zip archive). Thanks @TheCakeIsNaOH for revealing this shortcoming in chocolatey/choco#2520.

@vladimiry
Copy link
Owner

vladimiry commented Jan 27, 2022

I just contacted the site admins as an author of the app via https://community.chocolatey.org/packages/electron-mail/4.13.2/ContactAdmins Hope this will speed up the approval process.

@vladimiry vladimiry mentioned this issue Jan 28, 2022
@dhbtfs
Copy link

dhbtfs commented Jan 28, 2022

Fair enough, didnt know it was requested before. Thanks for the update.

@vladimiry
Copy link
Owner

vladimiry commented Jan 31, 2022

I just contacted the site admins as an author of the app via https://community.chocolatey.org/packages/electron-mail/4.13.2/ContactAdmins Hope this will speed up the approval process.

Based on the received response from moderators it looks like the package is going to get a "trusted" status not earlier than a few couples of versions get published. My understanding is that right now, without a "trusted" status, the Choco repo is sort of pointless since approving takes forever and can potentially take longer than a new/next version gets published.

@RAYs3T
Copy link
Author

RAYs3T commented Feb 1, 2022

Even then I think it should be kept so that in a few version in might acquire this state as it is really useful.

@vladimiry
Copy link
Owner

It's now approved, thanks @TheCakeIsNaOH. So the issue got closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants