Skip to content

Commit bb6f3eb

Browse files
committed
fix: update zebradesigner packages
1 parent 51e9f53 commit bb6f3eb

File tree

8 files changed

+312
-0
lines changed

8 files changed

+312
-0
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# ![ZebraDesigner-Developers Logo](https://cdn.jsdelivr.net/gh/mikeee/ChocoPackages/icons/zebradesigner.png "zebradesigner-developers Logo") [zebradesigner-developers](https://chocolatey.org/packages/zebradesigner-developers)
2+
3+
ZebraDesigner for Developers is barcode label software
4+
5+
**NOTE**: This package is automatically updated. If it is out of date and there is no newer package submitted, please use the `Contact Maintainers` functionality to alert them.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
$ErrorActionPreference = 'Stop';
2+
3+
$packageArgs = @{
4+
packageName = $env:ChocolateyPackageName
5+
url = 'https://www.zebra.com/content/dam/support-dam/en/application/unrestricted/0001/zebradesigner3-developers-322649.exe'
6+
checksum = 'c0bfd7534fcfb283109fd78ce1a87ea06124baf28ce2819eb45d9abda107c285'
7+
checksumType = 'SHA256'
8+
fileType = 'EXE'
9+
silentArgs = 'ICONDESKTOP=FALSE /s'
10+
validExitCodes = @(0)
11+
}
12+
13+
Install-ChocolateyPackage @packageArgs
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
#import-module au
2+
3+
. $PSScriptRoot\..\..\scripts\all.ps1
4+
5+
$releases = 'https://zebra.my.site.com/ChineseCommunity/articles/en_US/Knowledge/000022299'
6+
7+
function global:au_SearchReplace {
8+
@{
9+
".\tools\chocolateyInstall.ps1" = @{
10+
'(^\s*url\s*=\s*)(''.*'')' = "`$1'$($Latest.URL)'"
11+
"(?i)(^\s*checksum\s*=\s*)('.*')" = "`$1'$($Latest.Checksum)'"
12+
"(?i)(^\s*checksumType\s*=\s*)('.*')" = "`$1'$($Latest.ChecksumType)'"
13+
}
14+
}
15+
}
16+
17+
function global:au_BeforeUpdate {
18+
$Latest.Checksum = Get-RemoteChecksum $Latest.URL
19+
$Latest.ChecksumType = 'SHA256'
20+
}
21+
22+
function global:au_AfterUpdate {
23+
Set-DescriptionFromReadme -SkipFirst 2
24+
}
25+
26+
function global:au_GetLatest {
27+
$page = Invoke-WebRequest -Uri $releases -UseBasicParsing
28+
$regexVersion = 'zebradesigner(?<versionmajor>[\d])-developers-(?<versionminor>[\d]+).exe'
29+
30+
$matched = $page.Content -match $regexVersion
31+
32+
$versionMajor =
33+
34+
If ($False -ne $matchedurl) {
35+
$url = -join("https://www.zebra.com/content/dam/support-dam/en/application/unrestricted/0001/zebradesigner", $matches["versionmajor"], "-developers-", $matches["versionminor"], ".exe")
36+
$version = -join($matches["versionmajor"], ".", $matches["versionminor"])
37+
}
38+
39+
return @{
40+
URL = $url
41+
Version = $version
42+
}
43+
}
44+
45+
Update-Package
Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<!-- Read this before creating packages: https://chocolatey.org/docs/create-packages -->
3+
<!-- It is especially important to read the above link to understand additional requirements when
4+
publishing packages to the community feed aka dot org (https://chocolatey.org/packages). -->
5+
<!-- Test your packages in a test environment:
6+
https://github.com/chocolatey/chocolatey-test-environment -->
7+
<!--
8+
This is a nuspec. It mostly adheres to https://docs.nuget.org/create/Nuspec-Reference. Chocolatey
9+
uses a special version of NuGet.Core that allows us to do more than was initially possible. As such
10+
there are certain things to be aware of:
11+
* the package xmlns schema url may cause issues with nuget.exe
12+
* Any of the following elements can ONLY be used by choco tools - projectSourceUrl, docsUrl,
13+
mailingListUrl, bugTrackerUrl, packageSourceUrl, provides, conflicts, replaces
14+
* nuget.exe can still install packages with those elements but they are ignored. Any authoring
15+
tools or commands will error on those elements
16+
-->
17+
<!-- You can embed software files directly into packages, as long as you are not bound by
18+
distribution rights. -->
19+
<!-- * If you are an organization making private packages, you probably have no issues here -->
20+
<!-- * If you are releasing to the community feed, you need to consider distribution rights. -->
21+
<package xmlns="http://schemas.microsoft.com/packaging/2015/06/nuspec.xsd">
22+
<metadata>
23+
<!-- == PACKAGE SPECIFIC SECTION == -->
24+
<!-- This section is about this package, although id and version have ties back to the
25+
software -->
26+
<!-- id is lowercase and if you want a good separator for words, use '-', not '.'. Dots are
27+
only acceptable as suffixes for certain types of packages, e.g. .install, .portable,
28+
.extension, .template -->
29+
<!-- If the software is cross-platform, attempt to use the same id as the debian/rpm
30+
package(s) if possible. -->
31+
<id>zebradesigner-developers</id>
32+
<!-- version should MATCH as closely as possible with the underlying software -->
33+
<!-- Is the version a prerelease of a version?
34+
https://docs.nuget.org/create/versioning#creating-prerelease-packages -->
35+
<!-- Note that unstable versions like 0.0.1 can be considered a released version, but it's
36+
possible that one can release a 0.0.1-beta before you release a 0.0.1 version. If the
37+
version number is final, that is considered a released version and not a prerelease. -->
38+
<version>3.322649.1</version>
39+
<packageSourceUrl>https://github.com/mikeee/ChocoPackages/tree/master/automatic/zebradesigner-developers</packageSourceUrl>
40+
<!-- owners is a poor name for maintainers of the package. It sticks around by this name for
41+
compatibility reasons. It basically means you. -->
42+
<owners>mikeee</owners>
43+
<!-- ============================== -->
44+
<!-- == SOFTWARE SPECIFIC SECTION == -->
45+
<!-- This section is about the software itself -->
46+
<title>ZebraDesigner for Developers</title>
47+
<authors>Zebra Technologies Corp.</authors>
48+
<!-- projectUrl is required for the community feed -->
49+
<projectUrl>https://www.zebra.com/gb/en/products/software/barcode-printers/print-dna/zebradesigner-developer.html</projectUrl>
50+
<iconUrl>https://cdn.jsdelivr.net/gh/mikeee/ChocoPackages/icons/zebradesigner.png</iconUrl>
51+
<copyright>2023 Zebra Technologies Corp.</copyright>
52+
<!-- If there is a license Url available, it is is required for the community feed -->
53+
<licenseUrl>https://www.zebra.com/us/en/about-zebra/company-information/legal/open-source-usage.html</licenseUrl>
54+
<requireLicenseAcceptance>false</requireLicenseAcceptance>
55+
<!-- <projectSourceUrl></projectSourceUrl> -->
56+
<docsUrl>https://supportcommunity.zebra.com/s/global-search/ZebraDesigner%20for%20Developers%203?language=en_US</docsUrl>
57+
<!--<mailingListUrl></mailingListUrl>-->
58+
<!--<bugTrackerUrl></bugTrackerUrl>-->
59+
<tags>zebra designer essentials professional developers developer dev</tags>
60+
<summary>Label making software</summary>
61+
<description>ZebraDesigner for Developers is barcode label software
62+
63+
**NOTE**: This package is automatically updated. If it is out of date and there is no newer package submitted, please use the `Contact Maintainers` functionality to alert them.
64+
</description>
65+
<releaseNotes>https://www.zebra.com/gb/en/support-downloads/printer-software/zebra-designer-3-developer.html</releaseNotes>
66+
<!-- =============================== -->
67+
<!-- Specifying dependencies and version ranges?
68+
https://docs.nuget.org/create/versioning#specifying-version-ranges-in-.nuspec-files -->
69+
<dependencies>
70+
<!-- <dependency id="autohotkey" /> -->
71+
<!-- <dependency id="" version="[__EXACT_VERSION__]" /> -->
72+
<!-- <dependency id="" version="[_MIN_VERSION_INCLUSIVE, MAX_VERSION_EXCLUSIVE)" /> -->
73+
<!-- <dependency id="" /> -->
74+
<!-- <dependency id="chocolatey-uninstall.extension" /> -->
75+
</dependencies>
76+
<!-- chocolatey-uninstall.extension - If supporting 0.9.9.x (or below) and including a
77+
chocolateyUninstall.ps1 file to uninstall an EXE/MSI, you probably want to include
78+
chocolatey-uninstall.extension as a dependency. Please verify whether you are using a helper
79+
function from that package. -->
80+
<!--<provides>NOT
81+
YET IMPLEMENTED</provides>-->
82+
<!--<conflicts>NOT
83+
YET IMPLEMENTED</conflicts>-->
84+
<!--<replaces>NOT
85+
YET IMPLEMENTED</replaces>-->
86+
</metadata>
87+
<files>
88+
<!-- this section controls what actually gets packaged into the Chocolatey package -->
89+
<file src="tools\**" target="tools" />
90+
<!--Building
91+
from Linux? You may need this instead: <file src="tools/**" target="tools" />-->
92+
</files>
93+
</package>

automatic/zebradesigner/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# ![ZebraDesigner Logo](https://cdn.jsdelivr.net/gh/mikeee/ChocoPackages/icons/zebradesigner.png "zebradesigner Logo") [zebradesigner](https://chocolatey.org/packages/zebradesigner)
2+
3+
ZebraDesigner is barcode label software
4+
5+
**NOTE**: This package is automatically updated. If it is out of date and there is no newer package submitted, please use the `Contact Maintainers` functionality to alert them.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
$ErrorActionPreference = 'Stop';
2+
3+
$packageArgs = @{
4+
packageName = $env:ChocolateyPackageName
5+
url = 'https://www.zebra.com/content/dam/support-dam/en/application/unrestricted/0001/zebradesigner3-322649.exe'
6+
checksum = '7559325dc099f7f8da8b468a930b49ed4403aef498f2767f78bc8278fc001d97'
7+
checksumType = 'SHA256'
8+
fileType = 'EXE'
9+
silentArgs = 'ICONDESKTOP=FALSE /s'
10+
validExitCodes = @(0)
11+
}
12+
13+
Install-ChocolateyPackage @packageArgs

automatic/zebradesigner/update.ps1

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
#import-module au
2+
3+
. $PSScriptRoot\..\..\scripts\all.ps1
4+
5+
$releases = 'https://zebra.my.site.com/ChineseCommunity/articles/en_US/Knowledge/000022299'
6+
7+
function global:au_SearchReplace {
8+
@{
9+
".\tools\chocolateyInstall.ps1" = @{
10+
'(^\s*url\s*=\s*)(''.*'')' = "`$1'$($Latest.URL)'"
11+
"(?i)(^\s*checksum\s*=\s*)('.*')" = "`$1'$($Latest.Checksum)'"
12+
"(?i)(^\s*checksumType\s*=\s*)('.*')" = "`$1'$($Latest.ChecksumType)'"
13+
}
14+
}
15+
}
16+
17+
function global:au_BeforeUpdate {
18+
$Latest.Checksum = Get-RemoteChecksum $Latest.URL
19+
$Latest.ChecksumType = 'SHA256'
20+
}
21+
22+
function global:au_AfterUpdate {
23+
Set-DescriptionFromReadme -SkipFirst 2
24+
}
25+
26+
function global:au_GetLatest {
27+
$page = Invoke-WebRequest -Uri $releases -UseBasicParsing
28+
$regexVersion = 'zebradesigner(?<versionmajor>[\d])-(?<versionminor>[\d]+).exe'
29+
30+
$matched = $page.Content -match $regexVersion
31+
32+
$versionMajor =
33+
34+
If ($False -ne $matchedurl) {
35+
$url = -join("https://www.zebra.com/content/dam/support-dam/en/application/unrestricted/0001/zebradesigner", $matches["versionmajor"], "-", $matches["versionminor"], ".exe")
36+
$version = -join($matches["versionmajor"], ".", $matches["versionminor"])
37+
}
38+
39+
return @{
40+
URL = $url
41+
Version = $version
42+
}
43+
}
44+
45+
Update-Package
Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<!-- Read this before creating packages: https://chocolatey.org/docs/create-packages -->
3+
<!-- It is especially important to read the above link to understand additional requirements when
4+
publishing packages to the community feed aka dot org (https://chocolatey.org/packages). -->
5+
<!-- Test your packages in a test environment:
6+
https://github.com/chocolatey/chocolatey-test-environment -->
7+
<!--
8+
This is a nuspec. It mostly adheres to https://docs.nuget.org/create/Nuspec-Reference. Chocolatey
9+
uses a special version of NuGet.Core that allows us to do more than was initially possible. As such
10+
there are certain things to be aware of:
11+
* the package xmlns schema url may cause issues with nuget.exe
12+
* Any of the following elements can ONLY be used by choco tools - projectSourceUrl, docsUrl,
13+
mailingListUrl, bugTrackerUrl, packageSourceUrl, provides, conflicts, replaces
14+
* nuget.exe can still install packages with those elements but they are ignored. Any authoring
15+
tools or commands will error on those elements
16+
-->
17+
<!-- You can embed software files directly into packages, as long as you are not bound by
18+
distribution rights. -->
19+
<!-- * If you are an organization making private packages, you probably have no issues here -->
20+
<!-- * If you are releasing to the community feed, you need to consider distribution rights. -->
21+
<package xmlns="http://schemas.microsoft.com/packaging/2015/06/nuspec.xsd">
22+
<metadata>
23+
<!-- == PACKAGE SPECIFIC SECTION == -->
24+
<!-- This section is about this package, although id and version have ties back to the
25+
software -->
26+
<!-- id is lowercase and if you want a good separator for words, use '-', not '.'. Dots are
27+
only acceptable as suffixes for certain types of packages, e.g. .install, .portable,
28+
.extension, .template -->
29+
<!-- If the software is cross-platform, attempt to use the same id as the debian/rpm
30+
package(s) if possible. -->
31+
<id>zebradesigner</id>
32+
<!-- version should MATCH as closely as possible with the underlying software -->
33+
<!-- Is the version a prerelease of a version?
34+
https://docs.nuget.org/create/versioning#creating-prerelease-packages -->
35+
<!-- Note that unstable versions like 0.0.1 can be considered a released version, but it's
36+
possible that one can release a 0.0.1-beta before you release a 0.0.1 version. If the
37+
version number is final, that is considered a released version and not a prerelease. -->
38+
<version>3.322649.1</version>
39+
<packageSourceUrl>https://github.com/mikeee/ChocoPackages/tree/master/automatic/zebradesigner</packageSourceUrl>
40+
<!-- owners is a poor name for maintainers of the package. It sticks around by this name for
41+
compatibility reasons. It basically means you. -->
42+
<owners>mikeee</owners>
43+
<!-- ============================== -->
44+
<!-- == SOFTWARE SPECIFIC SECTION == -->
45+
<!-- This section is about the software itself -->
46+
<title>ZebraDesigner</title>
47+
<authors>Zebra Technologies Corp.</authors>
48+
<!-- projectUrl is required for the community feed -->
49+
<projectUrl>https://www.zebra.com/gb/en/products/software/barcode-printers/print-dna/zebra-designer.html</projectUrl>
50+
<iconUrl>https://cdn.jsdelivr.net/gh/mikeee/ChocoPackages/icons/zebradesigner.png</iconUrl>
51+
<copyright>2023 Zebra Technologies Corp.</copyright>
52+
<!-- If there is a license Url available, it is is required for the community feed -->
53+
<licenseUrl>https://www.zebra.com/us/en/about-zebra/company-information/legal/open-source-usage.html</licenseUrl>
54+
<requireLicenseAcceptance>false</requireLicenseAcceptance>
55+
<!-- <projectSourceUrl></projectSourceUrl> -->
56+
<docsUrl>https://supportcommunity.zebra.com/s/global-search/zebradesigner%203?language=en_US</docsUrl>
57+
<!--<mailingListUrl></mailingListUrl>-->
58+
<!--<bugTrackerUrl></bugTrackerUrl>-->
59+
<tags>zebra designer essentials professional</tags>
60+
<summary>Label making software</summary>
61+
<description>ZebraDesigner is barcode label software
62+
63+
**NOTE**: This package is automatically updated. If it is out of date and there is no newer package submitted, please use the `Contact Maintainers` functionality to alert them.
64+
</description>
65+
<releaseNotes>https://www.zebra.com/us/en/support-downloads/printer-software/zebra-designer-3-downloads.html</releaseNotes>
66+
<!-- =============================== -->
67+
<!-- Specifying dependencies and version ranges?
68+
https://docs.nuget.org/create/versioning#specifying-version-ranges-in-.nuspec-files -->
69+
<dependencies>
70+
<!-- <dependency id="autohotkey" /> -->
71+
<!-- <dependency id="" version="[__EXACT_VERSION__]" /> -->
72+
<!-- <dependency id="" version="[_MIN_VERSION_INCLUSIVE, MAX_VERSION_EXCLUSIVE)" /> -->
73+
<!-- <dependency id="" /> -->
74+
<!-- <dependency id="chocolatey-uninstall.extension" /> -->
75+
</dependencies>
76+
<!-- chocolatey-uninstall.extension - If supporting 0.9.9.x (or below) and including a
77+
chocolateyUninstall.ps1 file to uninstall an EXE/MSI, you probably want to include
78+
chocolatey-uninstall.extension as a dependency. Please verify whether you are using a helper
79+
function from that package. -->
80+
<!--<provides>NOT
81+
YET IMPLEMENTED</provides>-->
82+
<!--<conflicts>NOT
83+
YET IMPLEMENTED</conflicts>-->
84+
<!--<replaces>NOT
85+
YET IMPLEMENTED</replaces>-->
86+
</metadata>
87+
<files>
88+
<!-- this section controls what actually gets packaged into the Chocolatey package -->
89+
<file src="tools\**" target="tools" />
90+
<!--Building
91+
from Linux? You may need this instead: <file src="tools/**" target="tools" />-->
92+
</files>
93+
</package>

0 commit comments

Comments
 (0)