pauby / ChocoPackages

Chocolatey packages I maintain
26 stars 37 forks source link

Fix update script of the Yubico Authenticator and Yubico PIV tool #180

Closed xlammertink closed 1 year ago

xlammertink commented 1 year ago

Description

As the Yubico Authenticator was not up to date with the latest version (see issue https://github.com/pauby/ChocoPackages/issues/179), I tried packing and installing it manually. During this process I noticed that the updater script provided an error while updating the release notes, causing the updater to fail. This PR will fix the error.

As mentioned in https://github.com/majkinetor/au/issues/163, it's not possible to perform a search and replace over multiple lines. Therefore I've replaced the actual release notes in the .nuspec file with a URL that points to the release notes and changed the updater script to provide the URL in future updates.

Update: I've also included a fix for issue https://github.com/pauby/ChocoPackages/issues/181, related to the Yubico PIV tool. Here the updater failed due to the use of wrong quotation in the search and replace function.

Motivation and Context

This will ensure that the updater script will run properly without errors.

How Has this Been Tested?

cd automatic/yubico-authenticator
.\update.ps1
choco pack
choco install yubico-authenticator.6.2.0.nupkg
cd automatic/yubico-piv-tool
.\update.ps1
choco pack
choco install yubico-piv-tool.2.3.1.0.nupkg

Screenshot (if appropriate, usually isn't needed):

Not applicable.

Types of changes

Checklist:

Not applicable:

xlammertink commented 1 year ago

@pauby, could you take a look at this one and merge if you feel comfortable :)

xlammertink commented 1 year ago

While checking the status on this PR I noticed another Yubico tool was reported to be broken in issue https://github.com/pauby/ChocoPackages/issues/181. I've checked the issue and noticed it was related to the quotation in search and replace function in the upgrade script.

I've tested the other Yubico tools as well, but those worked perfectly fine.

pauby commented 1 year ago

I've merged this now and the latest versions of authenticator and piv-tool have both been pushed. Thanks @xlammertink for the updates. It is appreciated. Apologies for the delay in getting it merged.