Skip to content

Commit

Permalink
Merge pull request chocolatey-community#2356 from TheCakeIsNaOH/calibre
Browse files Browse the repository at this point in the history
(calibre) update AU script for v7.x
  • Loading branch information
gep13 authored Dec 21, 2023
2 parents 6e97b2f + 9f4d8d1 commit 54db3fd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions automatic/calibre/update.ps1
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import-module au
Import-Module "$PSScriptRoot\..\..\scripts\au_extensions.psm1"

$releases = 'https://download.calibre-ebook.com/6.html'
$releases = 'https://download.calibre-ebook.com/7.html'

function global:au_BeforeUpdate {
Get-RemoteFiles -Purge -NoSuffix
Expand Down Expand Up @@ -29,7 +29,7 @@ function global:au_GetLatest {
$download_page = Invoke-WebRequest -Uri $releases

$versionHyperlink = $download_page.links | Select-Object -First 1
if ($versionHyperlink.Title -notmatch 'Release (6[\d\.]+)' ) { throw "Calibre version 6.x not found on $releases" }
if ($versionHyperlink.Title -notmatch 'Release (7[\d\.]+)' ) { throw "Calibre version 7.x not found on $releases" }

$version = $versionHyperlink.InnerText
$url64 = 'https://download.calibre-ebook.com/<version>/calibre-64bit-<version>.msi'
Expand Down

0 comments on commit 54db3fd

Please sign in to comment.