From 79ea2aa1f7eca3f330dbf931bc1af9485f9472fa Mon Sep 17 00:00:00 2001 From: teknowledgist Date: Mon, 14 Aug 2023 14:32:57 -0400 Subject: [PATCH 1/7] Overhauled AHK script for v2 The Tixoti package has an "open" dependency on AutoHotKey. V2 of AHK has significantly different syntax, so the script had to be rewritten. This requires AHK v2 now, but it seems to be working. --- automatic/tixati/tixati.nuspec | 4 +-- automatic/tixati/tools/chocolateyInstall.ps1 | 31 ++++++++-------- automatic/tixati/tools/tixati.ahk | 37 +++++++++++--------- 3 files changed, 40 insertions(+), 32 deletions(-) diff --git a/automatic/tixati/tixati.nuspec b/automatic/tixati/tixati.nuspec index 1473618b115..2f033a17771 100644 --- a/automatic/tixati/tixati.nuspec +++ b/automatic/tixati/tixati.nuspec @@ -35,14 +35,14 @@ __Tixati__ is one of the most advanced and flexible BitTorrent clients available * **If the package is out of date please check [Version History](#versionhistory) for the latest submitted version. If you have a question, please ask it in [Chocolatey Community Package Discussions](https://github.com/chocolatey-community/chocolatey-packages/discussions) or raise an issue on the [Chocolatey Community Packages Repository](https://github.com/chocolatey-community/chocolatey-packages/issues) if you have problems with the package. Disqus comments will generally not be responded to.** ]]> http://www.tixati.com/ - internet network download torrent p2p share admin freeware + tixati bittorrent network download torrent p2p share freeware notsilent http://www.tixati.com/tixati_eula.txt false https://cdn.jsdelivr.net/gh/chocolatey-community/chocolatey-packages@bee4bc391df114723011dbd5b8a8af2a17c6bf2e/icons/tixati.png - + https://github.com/chocolatey-community/chocolatey-packages/tree/master/automatic/tixati diff --git a/automatic/tixati/tools/chocolateyInstall.ps1 b/automatic/tixati/tools/chocolateyInstall.ps1 index 56ab08a18ed..733a2d40d0c 100644 --- a/automatic/tixati/tools/chocolateyInstall.ps1 +++ b/automatic/tixati/tools/chocolateyInstall.ps1 @@ -1,29 +1,32 @@ $ErrorActionPreference = 'Stop' -$packageName = 'tixati' -$fileName = 'tixati-3.19-1.install.exe' -$download_dir = "$Env:TEMP\chocolatey\$packageName\$Env:ChocolateyPackageVersion" +$toolsDir = Split-Path -parent $MyInvocation.MyCommand.Definition +$DLFileName = 'tixati-3.19-1.install.exe' +$DLdir = "$Env:TEMP\chocolatey\$Env:ChocolateyPackageName\$Env:ChocolateyPackageVersion" $packageArgs = @{ - packageName = $packageName - fileFullPath = "$download_dir\$fileName" + packageName = $Env:ChocolateyPackageName + fileFullPath = Join-path $DLdir $DLFileName url = 'https://download1.tixati.com/download/tixati-3.19-1.win32-install.exe' url64bit = 'https://download1.tixati.com/download/tixati-3.19-1.win64-install.exe' checksum = 'aba530275d136a63e927807d75a3d5ceb30990d15eedf00a12f5bd247f79b5e0' checksum64 = 'c696960f8bdade39e3a73d6a7626dbd9ecb79f8c9335c8ea1220015a55627692' checksumType = 'sha256' - checksumType64 = 'sha256' } Get-ChocolateyWebFile @packageArgs -Write-Output "Running Autohotkey installer" -$toolsPath = Split-Path $MyInvocation.MyCommand.Definition -Autohotkey.exe $toolsPath\$packageName.ahk $packageArgs.fileFullPath +# silent install requires AutoHotKey +$ahkFile = Join-Path $toolsDir "$Env:ChocolateyPackageName.ahk" +$ahkProc = Start-Process -FilePath AutoHotkey.exe -ArgumentList "$ahkFile" -PassThru +Write-Debug "AutoHotKey start time:`t$($ahkProc.StartTime.ToShortTimeString())" +Write-Debug "AutoHotKey Process ID:`t$($ahkProc.Id)" -$installLocation = Get-AppInstallLocation $packageName +Start-ChocolateyProcessAsAdmin -ExeToRun $packageArgs.fileFullPath + +$installLocation = Get-AppInstallLocation $Env:ChocolateyPackageName if ($installLocation) { - Write-Host "$packageName installed to '$installLocation'" - Register-Application "$installLocation\$packageName.exe" - Write-Host "$packageName registered as $packageName" + Write-Host "$Env:ChocolateyPackageName installed to '$installLocation'" + Register-Application "$installLocation\$Env:ChocolateyPackageName.exe" + Write-Host "$Env:ChocolateyPackageName registered as $Env:ChocolateyPackageName" } -else { Write-Warning "Can't find $PackageName install location" } +else { Write-Warning "Can't find $Env:ChocolateyPackageName install location" } diff --git a/automatic/tixati/tools/tixati.ahk b/automatic/tixati/tools/tixati.ahk index 8e2d389c81b..6572d0e3537 100644 --- a/automatic/tixati/tools/tixati.ahk +++ b/automatic/tixati/tools/tixati.ahk @@ -1,20 +1,25 @@ -SetTitleMatchMode, RegEx -exe_re = tixati-.+install.exe +SetTitleMatchMode "RegEx" +exe_re := "tixati-.+install.exe" -Run %1% -WinWait, ahk_exe %exe_re%,,20 -IfNotEqual, ErrorLevel, 0, exit 1 -ControlSend,, {ENTER}, ahk_exe %exe_re% +If WinWait("ahk_exe " exe_re, , 20) + ControlSend "{ENTER}",, "ahk_exe " exe_re +Else + exit 1 -WinWait, ahk_exe %exe_re%, YES`, continue installation, 20 -IfNotEqual, ErrorLevel, 0, exit 1 -ControlSend,, {ENTER}, ahk_exe %exe_re% +If WinWait("ahk_exe " exe_re, "YES`, continue installation", 20) + ControlSend "{ENTER}",, "ahk_exe " exe_re +Else + exit 1 -WinWait, ahk_exe %exe_re%, Install, 20 -IfNotEqual, ErrorLevel, 0, exit 1 -ControlSend,, {ENTER}, ahk_exe %exe_re% +If WinWait("ahk_exe " exe_re, "Install", 20) + ControlSend "{ENTER}",, "ahk_exe " exe_re +Else + exit 1 -WinWait, ahk_exe %exe_re%, Installation is complete!, 20 -IfNotEqual, ErrorLevel, 0, exit 1 -WinActivate -Send, {TAB}{ENTER} +if WinWait("ahk_exe " exe_re, "Installation is complete!", 20) +{ + WinActivate + Send "{TAB}{ENTER}" +} +Else + exit 1 From 616cad306d3962dfc3e0ced57661a992bbf862de Mon Sep 17 00:00:00 2001 From: teknowledgist Date: Mon, 14 Aug 2023 15:04:27 -0400 Subject: [PATCH 2/7] Update chocolateyInstall.ps1 --- automatic/tixati/tools/chocolateyInstall.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/automatic/tixati/tools/chocolateyInstall.ps1 b/automatic/tixati/tools/chocolateyInstall.ps1 index 733a2d40d0c..e6bfff99220 100644 --- a/automatic/tixati/tools/chocolateyInstall.ps1 +++ b/automatic/tixati/tools/chocolateyInstall.ps1 @@ -1,12 +1,12 @@ $ErrorActionPreference = 'Stop' $toolsDir = Split-Path -parent $MyInvocation.MyCommand.Definition -$DLFileName = 'tixati-3.19-1.install.exe' +$fileName = 'tixati-3.19-1.install.exe' $DLdir = "$Env:TEMP\chocolatey\$Env:ChocolateyPackageName\$Env:ChocolateyPackageVersion" $packageArgs = @{ packageName = $Env:ChocolateyPackageName - fileFullPath = Join-path $DLdir $DLFileName + fileFullPath = Join-path $DLdir $fileName url = 'https://download1.tixati.com/download/tixati-3.19-1.win32-install.exe' url64bit = 'https://download1.tixati.com/download/tixati-3.19-1.win64-install.exe' checksum = 'aba530275d136a63e927807d75a3d5ceb30990d15eedf00a12f5bd247f79b5e0' From f7be67637b231a9e9026c7592f033a6b6d688baa Mon Sep 17 00:00:00 2001 From: teknowledgist Date: Mon, 30 Sep 2024 12:57:33 -0400 Subject: [PATCH 3/7] (zotero) add 64-bit installer This adds the new install option for 64-bit Zotero and simplifies the update a bit. --- automatic/zotero/Readme.md | 2 +- automatic/zotero/legal/LICENSE.txt | 15 +++++--- automatic/zotero/legal/VERIFICATION.txt | 28 +++++++++------ automatic/zotero/tools/chocolateyInstall.ps1 | 20 ++++++----- .../zotero/tools/chocolateyUninstall.ps1 | 2 +- automatic/zotero/update.ps1 | 36 ++++++++----------- automatic/zotero/zotero.nuspec | 30 ++++++++-------- 7 files changed, 72 insertions(+), 61 deletions(-) diff --git a/automatic/zotero/Readme.md b/automatic/zotero/Readme.md index 447d009b8c9..a533da32a7a 100644 --- a/automatic/zotero/Readme.md +++ b/automatic/zotero/Readme.md @@ -3,4 +3,4 @@ Zotero is free and open-source reference management software to manage bibliographic data and related research materials (such as PDF files). Notable features include web browser integration, online syncing, generation of in-text citations, footnotes and bibliographies, as well as integration with the word processors Microsoft Word, LibreOffice, OpenOffice.org Writer and NeoOffice. -![screenshot](https://cdn.rawgit.com/chocolatey/chocolatey-coreteampackages/d1d9f0154e370315e49f245a26a7d23e89a705cc/automatic/zotero/screenshot.png) +![screenshot](https://cdn.jsdelivr.net/gh/chocolatey-community/chocolatey-packages@53607633ce049d5d75ac668f4408faaeced36bc3/automatic/zotero/screenshot.png) diff --git a/automatic/zotero/legal/LICENSE.txt b/automatic/zotero/legal/LICENSE.txt index 929288f9811..96b5d3cd79a 100644 --- a/automatic/zotero/legal/LICENSE.txt +++ b/automatic/zotero/legal/LICENSE.txt @@ -1,12 +1,18 @@ -Zotero is Copyright © 2006, 2007, 2008, 2009, 2010, 2011 -Center for History and New Media, George Mason University, +Obtained from: https://raw.githubusercontent.com/zotero/zotero/refs/heads/main/COPYING +======================================================================================= + +Zotero is Copyright © 2018 Corporation for Digital Scholarship, +Vienna, Virginia, USA http://digitalscholar.org + +Copyright © 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017 +Roy Rosenzweig Center for History and New Media, George Mason University, Fairfax, Virginia, USA http://zotero.org -The Center for History and New Media distributes the Zotero source code +The Corporation for Digital Scholarship distributes the Zotero source code under the GNU Affero General Public License, version 3 (AGPLv3). The full text of this license is given below. -The Zotero name is a registered trademark of George Mason University. +The Zotero name is a registered trademark of the Corporation for Digital Scholarship. See http://zotero.org/trademark for more information. Third-party copyright in this distribution is noted where applicable. @@ -676,3 +682,4 @@ specific requirements. if any, to sign a "copyright disclaimer" for the program, if necessary. For more information on this, and how to apply and follow the GNU AGPL, see . + diff --git a/automatic/zotero/legal/VERIFICATION.txt b/automatic/zotero/legal/VERIFICATION.txt index d0119b42543..f2dba8a89a0 100644 --- a/automatic/zotero/legal/VERIFICATION.txt +++ b/automatic/zotero/legal/VERIFICATION.txt @@ -2,17 +2,23 @@ VERIFICATION Verification is intended to assist the Chocolatey moderators and community in verifying that this package's contents are trustworthy. -The embedded software have been downloaded from the listed download -location on (The listed url gets redirected to another one) -and can be verified by doing the following: +Package can be verified like this: -1. Download the following -2. Get the checksum using one of the following methods: - - Using powershell function 'Get-FileHash' - - Use chocolatey utility 'checksum.exe' -3. The checksums should match the following: +1. The installers can be obtained directly from: - checksum type: sha256 - checksum: DA8E5516D57DDE80812E76E122B7A2E86EDB57B61C25D8AD107C50C8FA4E52F3 + 32-bit download: https://download.zotero.org/client/release/7.0.5/Zotero-7.0.5_win32_setup.exe + 64-bit download: https://download.zotero.org/client/release/7.0.5/Zotero-7.0.5_x64_setup.exe -The file 'LICENSE.txt' has been obtained from + to download the installer. + +2. The following methods can calculate the SHA256 checksum of what you download + to allow you to compare against the checksums below: + - Use powershell function 'Get-FileHash' + - Use Chocolatey utility 'checksum.exe' + + 32-bit checksum: DA8E5516D57DDE80812E76E122B7A2E86EDB57B61C25D8AD107C50C8FA4E52F3 + 64-bit checksum: 43017A16C5D6C9748C6615D51464B0CBD7E1E42FE49EBDD556B46E47932E4737 + + +The content of the file 'LICENSE.txt' is copied from: + https://raw.githubusercontent.com/zotero/zotero/refs/heads/main/COPYING diff --git a/automatic/zotero/tools/chocolateyInstall.ps1 b/automatic/zotero/tools/chocolateyInstall.ps1 index 302becdede5..da1ffc02681 100644 --- a/automatic/zotero/tools/chocolateyInstall.ps1 +++ b/automatic/zotero/tools/chocolateyInstall.ps1 @@ -1,16 +1,20 @@ $ErrorActionPreference = 'Stop' -$toolsPath = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)" +$toolsPath = Split-Path -parent $MyInvocation.MyCommand.Definition +$Installers = Get-ChildItem -Path $toolsPath -Filter '*.exe' | + Sort-Object lastwritetime | + Select-Object -Last 2 -ExpandProperty FullName $packageArgs = @{ - packageName = $env:ChocolateyPackageName - fileType = 'exe' - silentArgs = '/S' - validExitCodes = @(0) - softwareName = 'Zotero' - file = "$toolsPath\Zotero-7.0.5_win32_setup.exe" + packageName = $env:ChocolateyPackageName + softwareName = "$env:ChocolateyPackageName*" + fileType = 'exe' + file = $Installers | Where-Object {$_ -match "win32"} + file64 = $Installers | Where-Object {$_ -match "x64"} + silentArgs = '/S' + validExitCodes = @(0) } Install-ChocolateyInstallPackage @packageArgs -Remove-Item -Force -ea 0 "$toolsPath\*.exe","$toolsPath\*.ignore" +Remove-Item $Installers -Force -ea 0 diff --git a/automatic/zotero/tools/chocolateyUninstall.ps1 b/automatic/zotero/tools/chocolateyUninstall.ps1 index f4b6f73efbe..9cdfc70531c 100644 --- a/automatic/zotero/tools/chocolateyUninstall.ps1 +++ b/automatic/zotero/tools/chocolateyUninstall.ps1 @@ -2,7 +2,7 @@ $packageArgs = @{ packageName = $env:ChocolateyPackageName - softwareName = 'Zotero' + softwareName = "$env:ChocolateyPackageName*" fileType = 'exe' silentArgs = '/S' validExitCodes= @(@(0)) diff --git a/automatic/zotero/update.ps1 b/automatic/zotero/update.ps1 index 788bfe64384..4331304ab29 100644 --- a/automatic/zotero/update.ps1 +++ b/automatic/zotero/update.ps1 @@ -1,8 +1,7 @@ Import-Module Chocolatey-AU Import-Module "$PSScriptRoot\..\..\scripts\au_extensions.psm1" -$releases = 'https://www.zotero.org/download/client/dl?channel=release&platform=win32' -$softwareName = 'Zotero' +$releases = 'https://www.zotero.org/download/client/dl?channel=release&platform=win-x64' function global:au_BeforeUpdate { Get-RemoteFiles -Purge -NoSuffix } @@ -11,32 +10,25 @@ function global:au_SearchReplace { @{ ".\legal\VERIFICATION.txt" = @{ - "(?i)(\s*1\..+)\<.*\>" = "`${1}<$($Latest.URL32)>" - "(?i)(^\s*checksum\s*type\:).*" = "`${1} $($Latest.ChecksumType32)" - "(?i)(^\s*checksum(32)?\:).*" = "`${1} $($Latest.Checksum32)" - } - ".\tools\chocolateyInstall.ps1" = @{ - "(?i)^(\s*softwareName\s*=\s*)'.*'" = "`${1}'$softwareName'" - "(?i)(^\s*file\s*=\s*`"[$]toolsPath\\).*" = "`${1}$($Latest.FileName32)`"" - } - ".\tools\chocolateyUninstall.ps1" = @{ - "(?i)^(\s*softwareName\s*=\s*)'.*'" = "`${1}'$softwareName'" - } - ".\$($Latest.PackageName).nuspec" = @{ - "(\).*(\<\/releaseNotes\>)" = "`${1}https://www.zotero.org/support/$($version.Major).$($version.Minor)_changelog`${2}" + "(?i)(^\s*32-bit download\:).*" = "`${1} $($Latest.URL32)" + "(?i)(^\s*64-bit download\:).*" = "`${1} $($Latest.URL64)" + "(?i)(^\s*32-bit checksum\:).*" = "`${1} $($Latest.Checksum32)" + "(?i)(^\s*64-bit checksum\:).*" = "`${1} $($Latest.Checksum64)" } } } function global:au_GetLatest { - $url = Get-RedirectedUrl -url $releases + $url64 = Get-RedirectedUrl -url $releases + $url32 = $url64 -replace 'x64','win32' - $version = $url -split '/' | Select-Object -Last 1 -Skip 1 + $version = $url64.split('/') | Where-Object {$_ -match '^[0-9.]+$'} - @{ - Version = $version - URL32 = $url - } + @{ + Version = $version + URL32 = $url32 + URL64 = $url64 + } } -update -ChecksumFor none +update -ChecksumFor none -force diff --git a/automatic/zotero/zotero.nuspec b/automatic/zotero/zotero.nuspec index 9b85f1d417b..dd6e570097e 100644 --- a/automatic/zotero/zotero.nuspec +++ b/automatic/zotero/zotero.nuspec @@ -2,30 +2,32 @@ + zotero - Zotero + 7.0.5.20240930 + https://github.com/chocolatey-community/chocolatey-packages/tree/master/automatic/zotero chocolatey-community - 7.0.5 - Center for History and New Media, et. al. - Zotero [zoh-TAIR-oh] is a free, easy-to-use tool to help you collect, organize, cite, and share your research sources. - https://cdn.jsdelivr.net/gh/chocolatey-community/chocolatey-packages@53607633ce049d5d75ac668f4408faaeced36bc3/icons/zotero.png - - + + Zotero + The Corporation for Digital Scholarship and contributors https://www.zotero.org/ - zotero references manager bibliography foss cross-platform admin + https://cdn.jsdelivr.net/gh/chocolatey-community/chocolatey-packages@53607633ce049d5d75ac668f4408faaeced36bc3/icons/zotero.png 2006-2011, Center for History and New Media, George Mason University, Fairfax, Virginia, USA https://github.com/zotero/zotero/blob/master/COPYING false - https://www.zotero.org/support/._changelog - https://github.com/chocolatey-community/chocolatey-packages/tree/master/automatic/zotero https://www.zotero.org/support/dev/source_code https://www.zotero.org/support https://forums.zotero.org/discussions https://github.com/zotero/zotero/issues + zotero references manager bibliography citations research foss cross-platform embedded + Zotero [zoh-TAIR-oh] is a free, easy-to-use tool to help you collect, organize, cite, and share your research sources. + + + https://www.zotero.org/support/changelog From c92090a77d177046eab95a5394c35c545d86f66a Mon Sep 17 00:00:00 2001 From: teknowledgist Date: Wed, 9 Oct 2024 21:35:29 -0400 Subject: [PATCH 4/7] (zotero) update to v7.0.7 --- automatic/zotero/legal/VERIFICATION.txt | 8 ++++---- automatic/zotero/zotero.nuspec | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/automatic/zotero/legal/VERIFICATION.txt b/automatic/zotero/legal/VERIFICATION.txt index f2dba8a89a0..c24c112e665 100644 --- a/automatic/zotero/legal/VERIFICATION.txt +++ b/automatic/zotero/legal/VERIFICATION.txt @@ -6,8 +6,8 @@ Package can be verified like this: 1. The installers can be obtained directly from: - 32-bit download: https://download.zotero.org/client/release/7.0.5/Zotero-7.0.5_win32_setup.exe - 64-bit download: https://download.zotero.org/client/release/7.0.5/Zotero-7.0.5_x64_setup.exe + 32-bit download: https://download.zotero.org/client/release/7.0.7/Zotero-7.0.7_win32_setup.exe + 64-bit download: https://download.zotero.org/client/release/7.0.7/Zotero-7.0.7_x64_setup.exe to download the installer. @@ -16,8 +16,8 @@ Package can be verified like this: - Use powershell function 'Get-FileHash' - Use Chocolatey utility 'checksum.exe' - 32-bit checksum: DA8E5516D57DDE80812E76E122B7A2E86EDB57B61C25D8AD107C50C8FA4E52F3 - 64-bit checksum: 43017A16C5D6C9748C6615D51464B0CBD7E1E42FE49EBDD556B46E47932E4737 + 32-bit checksum: 0189D2CB2114F77FEA18190B725E0C2F38FB6E17991809663956EE84A10136A3 + 64-bit checksum: EBA6DE61A660BAAC5865756DEC6D2D954919737F5F0C2F103AD4C92F7294B5B6 The content of the file 'LICENSE.txt' is copied from: diff --git a/automatic/zotero/zotero.nuspec b/automatic/zotero/zotero.nuspec index dd6e570097e..1b92224da04 100644 --- a/automatic/zotero/zotero.nuspec +++ b/automatic/zotero/zotero.nuspec @@ -4,7 +4,7 @@ zotero - 7.0.5.20240930 + 7.0.7 https://github.com/chocolatey-community/chocolatey-packages/tree/master/automatic/zotero chocolatey-community From efa2269a091bc8742dac2a9fb4888f042b669c8b Mon Sep 17 00:00:00 2001 From: teknowledgist Date: Tue, 29 Oct 2024 16:28:30 -0400 Subject: [PATCH 5/7] (zotero) changes by request --- automatic/zotero/legal/LICENSE.txt | 3 --- automatic/zotero/legal/VERIFICATION.txt | 21 +++++++++---------- automatic/zotero/tools/chocolateyInstall.ps1 | 17 ++++++++------- .../zotero/tools/chocolateyUninstall.ps1 | 4 ++-- automatic/zotero/update.ps1 | 16 +++++++------- automatic/zotero/zotero.nuspec | 6 +++--- 6 files changed, 34 insertions(+), 33 deletions(-) diff --git a/automatic/zotero/legal/LICENSE.txt b/automatic/zotero/legal/LICENSE.txt index 96b5d3cd79a..779d0cbf26a 100644 --- a/automatic/zotero/legal/LICENSE.txt +++ b/automatic/zotero/legal/LICENSE.txt @@ -1,6 +1,3 @@ -Obtained from: https://raw.githubusercontent.com/zotero/zotero/refs/heads/main/COPYING -======================================================================================= - Zotero is Copyright © 2018 Corporation for Digital Scholarship, Vienna, Virginia, USA http://digitalscholar.org diff --git a/automatic/zotero/legal/VERIFICATION.txt b/automatic/zotero/legal/VERIFICATION.txt index c24c112e665..e49edf720e3 100644 --- a/automatic/zotero/legal/VERIFICATION.txt +++ b/automatic/zotero/legal/VERIFICATION.txt @@ -4,21 +4,20 @@ in verifying that this package's contents are trustworthy. Package can be verified like this: -1. The installers can be obtained directly from: +1. Go to - 32-bit download: https://download.zotero.org/client/release/7.0.7/Zotero-7.0.7_win32_setup.exe - 64-bit download: https://download.zotero.org/client/release/7.0.7/Zotero-7.0.7_x64_setup.exe + x32: https://download.zotero.org/client/release/7.0.5/Zotero-7.0.5_win32_setup.exe + x64: https://download.zotero.org/client/release/7.0.5/Zotero-7.0.5_x64_setup.exe to download the installer. -2. The following methods can calculate the SHA256 checksum of what you download - to allow you to compare against the checksums below: - - Use powershell function 'Get-FileHash' - - Use Chocolatey utility 'checksum.exe' +2. Get the checksum using one of the following methods: + - Using powershell function 'Get-FileHash' + - Use chocolatey utility 'checksum.exe' +3. The checksums should match the following: - 32-bit checksum: 0189D2CB2114F77FEA18190B725E0C2F38FB6E17991809663956EE84A10136A3 - 64-bit checksum: EBA6DE61A660BAAC5865756DEC6D2D954919737F5F0C2F103AD4C92F7294B5B6 + checksum32: DA8E5516D57DDE80812E76E122B7A2E86EDB57B61C25D8AD107C50C8FA4E52F3 + checksum64: 43017a16c5d6c9748c6615d51464b0cbd7e1e42fe49ebdd556b46e47932e4737 - -The content of the file 'LICENSE.txt' is copied from: +The file 'LICENSE.txt' has been obtained from https://raw.githubusercontent.com/zotero/zotero/refs/heads/main/COPYING diff --git a/automatic/zotero/tools/chocolateyInstall.ps1 b/automatic/zotero/tools/chocolateyInstall.ps1 index da1ffc02681..07f44068c5b 100644 --- a/automatic/zotero/tools/chocolateyInstall.ps1 +++ b/automatic/zotero/tools/chocolateyInstall.ps1 @@ -1,20 +1,23 @@ $ErrorActionPreference = 'Stop' + $toolsPath = Split-Path -parent $MyInvocation.MyCommand.Definition -$Installers = Get-ChildItem -Path $toolsPath -Filter '*.exe' | - Sort-Object lastwritetime | - Select-Object -Last 2 -ExpandProperty FullName +$File32Name = 'Zotero-7.0.8_win32_setup.exe' +$File64Name = 'Zotero-7.0.8_x64_setup.exe' + +$File32Path = Join-Path $toolsPath $File32Name +$File64Path = Join-Path $toolsPath $File64Name $packageArgs = @{ packageName = $env:ChocolateyPackageName - softwareName = "$env:ChocolateyPackageName*" + softwareName = "Zotero*" fileType = 'exe' - file = $Installers | Where-Object {$_ -match "win32"} - file64 = $Installers | Where-Object {$_ -match "x64"} + file = "$File32Path" + file64 = "$File64Path" silentArgs = '/S' validExitCodes = @(0) } Install-ChocolateyInstallPackage @packageArgs -Remove-Item $Installers -Force -ea 0 +Remove-Item "$File32Path","$File64Path" -Force -ea 0 diff --git a/automatic/zotero/tools/chocolateyUninstall.ps1 b/automatic/zotero/tools/chocolateyUninstall.ps1 index 9cdfc70531c..26314b1a7e5 100644 --- a/automatic/zotero/tools/chocolateyUninstall.ps1 +++ b/automatic/zotero/tools/chocolateyUninstall.ps1 @@ -2,7 +2,7 @@ $packageArgs = @{ packageName = $env:ChocolateyPackageName - softwareName = "$env:ChocolateyPackageName*" + softwareName = "Zotero*" fileType = 'exe' silentArgs = '/S' validExitCodes= @(@(0)) @@ -19,7 +19,7 @@ if ($key.Count -eq 1) { Uninstall-ChocolateyPackage @packageArgs } } elseif ($key.Count -eq 0) { - Write-Warning "$packageName has already been uninstalled by other means." + Write-Warning "$env:ChocolateyPackageName has already been uninstalled by other means." } elseif ($key.Count -gt 1) { Write-Warning "$($key.Count) matches found!" Write-Warning "To prevent accidental data loss, no programs will be uninstalled." diff --git a/automatic/zotero/update.ps1 b/automatic/zotero/update.ps1 index 4331304ab29..9bed0084a04 100644 --- a/automatic/zotero/update.ps1 +++ b/automatic/zotero/update.ps1 @@ -6,14 +6,16 @@ $releases = 'https://www.zotero.org/download/client/dl?channel=release&platform= function global:au_BeforeUpdate { Get-RemoteFiles -Purge -NoSuffix } function global:au_SearchReplace { - $version = $Latest.Version.ToString() - @{ ".\legal\VERIFICATION.txt" = @{ - "(?i)(^\s*32-bit download\:).*" = "`${1} $($Latest.URL32)" - "(?i)(^\s*64-bit download\:).*" = "`${1} $($Latest.URL64)" - "(?i)(^\s*32-bit checksum\:).*" = "`${1} $($Latest.Checksum32)" - "(?i)(^\s*64-bit checksum\:).*" = "`${1} $($Latest.Checksum64)" + "(?i)(^\s*x32\:).*" = "`${1} $($Latest.URL32)" + "(?i)(^\s*x64\:).*" = "`${1} $($Latest.URL64)" + "(?i)(^\s*checksum32\:).*" = "`${1} $($Latest.Checksum32)" + "(?i)(^\s*checksum64\:).*" = "`${1} $($Latest.Checksum64)" + } + ".\tools\chocolateyInstall.ps1" = @{ + "(?i)(^[$]File32Name =).*" = "`${1} '$($Latest.URL32.split('/')[-1])'" + "(?i)(^[$]File64Name =).*" = "`${1} '$($Latest.URL64.split('/')[-1])'" } } } @@ -22,7 +24,7 @@ function global:au_GetLatest { $url64 = Get-RedirectedUrl -url $releases $url32 = $url64 -replace 'x64','win32' - $version = $url64.split('/') | Where-Object {$_ -match '^[0-9.]+$'} + $version = $url64 -split '/' | Where-Object {$_ -match '^\d+\.\d[0-9.]*$'} | Select-Object -Last 1 @{ Version = $version diff --git a/automatic/zotero/zotero.nuspec b/automatic/zotero/zotero.nuspec index 1b92224da04..65b167ed559 100644 --- a/automatic/zotero/zotero.nuspec +++ b/automatic/zotero/zotero.nuspec @@ -4,12 +4,12 @@ zotero - 7.0.7 + 7.0.5 https://github.com/chocolatey-community/chocolatey-packages/tree/master/automatic/zotero chocolatey-community Zotero - The Corporation for Digital Scholarship and contributors + Corporation for Digital Scholarship https://www.zotero.org/ https://cdn.jsdelivr.net/gh/chocolatey-community/chocolatey-packages@53607633ce049d5d75ac668f4408faaeced36bc3/icons/zotero.png 2006-2011, Center for History and New Media, George Mason University, Fairfax, Virginia, USA @@ -19,7 +19,7 @@ https://www.zotero.org/support https://forums.zotero.org/discussions https://github.com/zotero/zotero/issues - zotero references manager bibliography citations research foss cross-platform embedded + zotero productivity foss cross-platform references manager bibliography citations research embedded Zotero [zoh-TAIR-oh] is a free, easy-to-use tool to help you collect, organize, cite, and share your research sources. Date: Mon, 18 Nov 2024 09:08:36 -0500 Subject: [PATCH 6/7] Create .gitconfig Allow rebase commands in GUI. --- .gitconfig | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 .gitconfig diff --git a/.gitconfig b/.gitconfig new file mode 100644 index 00000000000..e9eb9f8bc2b --- /dev/null +++ b/.gitconfig @@ -0,0 +1,14 @@ +[guitool "Rebase onto..."] + cmd = git rebase $REVISION + revprompt = yes +[guitool "Rebase/Continue"] + cmd = git rebase --continue +[guitool "Rebase/Skip"] + cmd = git rebase --skip +[guitool "Rebase/Abort"] + cmd = git rebase --abort +[guitool "Pull with Rebase"] + cmd = git pull --rebase +[guitool "Rebase interactive"] + cmd = EDITOR=gvim git rebase -i $REVISION + revprompt = yes From 57a2b9d88bb2dce941ee65c6f03ca565eb5458e8 Mon Sep 17 00:00:00 2001 From: teknowledgist Date: Mon, 18 Nov 2024 09:13:53 -0500 Subject: [PATCH 7/7] Delete .gitconfig --- .gitconfig | 14 -------------- 1 file changed, 14 deletions(-) delete mode 100644 .gitconfig diff --git a/.gitconfig b/.gitconfig deleted file mode 100644 index e9eb9f8bc2b..00000000000 --- a/.gitconfig +++ /dev/null @@ -1,14 +0,0 @@ -[guitool "Rebase onto..."] - cmd = git rebase $REVISION - revprompt = yes -[guitool "Rebase/Continue"] - cmd = git rebase --continue -[guitool "Rebase/Skip"] - cmd = git rebase --skip -[guitool "Rebase/Abort"] - cmd = git rebase --abort -[guitool "Pull with Rebase"] - cmd = git pull --rebase -[guitool "Rebase interactive"] - cmd = EDITOR=gvim git rebase -i $REVISION - revprompt = yes