@smbcloud / cli / commits / 4e10a2f

Rename the winget package to smbCloud.CLI

Nothing is merged in winget-pkgs under the old identifier, so this is the cheapest point to drop the smbCloudXYZ publisher segment. The workflow also checked only for a merged package folder, so every release opened another New-package PR and Package Request issue while the first was still queued. It now looks for an open New-package PR and, if there is one, skips the issue, the wait and the submission. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

Seto Elkahfi committed Oct 20, 2026 at 09:04 UTC 4e10a2f1119a64a531e15f7d75e3c38e6b67f060
4 files changed +25 -8
.github/workflows/release-winget.yml
+22 -5
@@ -33,7 +33,7 @@ permissions:
33
34 env:
35 REPO: smbcloudXYZ/smbcloud-cli
36 - PACKAGE_IDENTIFIER: smbCloudXYZ.smbcloud-cli
36 + PACKAGE_IDENTIFIER: smbCloud.CLI
37
38 jobs:
39 submit-winget-manifest:
@@ -67,7 +67,7 @@ jobs:
67 GH_TOKEN: ${{ github.token }}
68 run: |
69 # manifests are filed under the lowercased first letter of the
70 - # publisher, e.g. manifests/s/smbCloudXYZ/smbcloud-cli.
70 + # publisher, e.g. manifests/s/smbCloud/CLI.
71 PUBLISHER="${PACKAGE_IDENTIFIER%%.*}"
72 NAME="${PACKAGE_IDENTIFIER#*.}"
73 FIRST=$(echo "${PUBLISHER:0:1}" | tr '[:upper:]' '[:lower:]')
@@ -76,13 +76,29 @@ jobs:
76 if gh api "repos/microsoft/winget-pkgs/contents/${PATH_IN_REPO}" >/dev/null 2>&1; then
77 echo "Found ${PACKAGE_IDENTIFIER} at ${PATH_IN_REPO}; submitting an update."
78 echo "found=true" >> "$GITHUB_OUTPUT"
79 + echo "pending=false" >> "$GITHUB_OUTPUT"
80 + exit 0
81 + fi
82 +
83 + echo "found=false" >> "$GITHUB_OUTPUT"
84 +
85 + # Until the first New-package PR merges the folder check above is
86 + # always false, so without this every release would open another
87 + # PR and Package Request issue for the same package.
88 + OPEN_PR=$(gh pr list --repo microsoft/winget-pkgs --state open \
89 + --search "New package: ${PACKAGE_IDENTIFIER} in:title" \
90 + --json number,url --jq '.[0].url // empty')
91 +
92 + if [ -n "$OPEN_PR" ]; then
93 + echo "No ${PACKAGE_IDENTIFIER} at ${PATH_IN_REPO}, but ${OPEN_PR} is already open; not submitting again."
94 + echo "pending=true" >> "$GITHUB_OUTPUT"
95 else
96 echo "No ${PACKAGE_IDENTIFIER} at ${PATH_IN_REPO}; submitting it as a new package."
81 - echo "found=false" >> "$GITHUB_OUTPUT"
97 + echo "pending=false" >> "$GITHUB_OUTPUT"
98 fi
99
100 - name: Render manifests for a first submission
85 - if: steps.exists.outputs.found == 'false'
101 + if: steps.exists.outputs.found == 'false' && steps.exists.outputs.pending != 'true'
102 shell: bash
103 env:
104 GH_TOKEN: ${{ github.token }}
@@ -141,6 +157,7 @@ jobs:
157 # WINGET_PR_TOKEN replaces the old single WINGET_TOKEN.
158 - name: File the winget Package Request issue
159 id: issue
160 + if: steps.exists.outputs.pending != 'true'
161 shell: bash
162 env:
163 # Authored by the issue account for this repo.
@@ -188,7 +205,7 @@ jobs:
205
206 - name: Submit new package
207 id: submit_new
191 - if: steps.exists.outputs.found == 'false'
208 + if: steps.exists.outputs.found == 'false' && steps.exists.outputs.pending != 'true'
209 shell: pwsh
210 env:
211 # wingetcreate reads the token from this variable. Passing it as
packaging/winget/smbCloud.CLI.installer.yaml.in renamed
+1 -1
@@ -1,5 +1,5 @@
1 # yaml-language-server: $schema=https://aka.ms/winget-manifest.installer.1.6.0.schema.json
2 -PackageIdentifier: smbCloudXYZ.smbcloud-cli
2 +PackageIdentifier: smbCloud.CLI
3 PackageVersion: @VERSION@
4 InstallerType: portable
5 # No VCRedist dependency: the exe links the C runtime statically
packaging/winget/smbCloud.CLI.locale.en-US.yaml.in renamed
+1 -1
@@ -1,5 +1,5 @@
1 # yaml-language-server: $schema=https://aka.ms/winget-manifest.defaultLocale.1.6.0.schema.json
2 -PackageIdentifier: smbCloudXYZ.smbcloud-cli
2 +PackageIdentifier: smbCloud.CLI
3 PackageVersion: @VERSION@
4 PackageLocale: en-US
5 Publisher: smbCloud
packaging/winget/smbCloud.CLI.yaml.in renamed
+1 -1
@@ -1,5 +1,5 @@
1 # yaml-language-server: $schema=https://aka.ms/winget-manifest.version.1.6.0.schema.json
2 -PackageIdentifier: smbCloudXYZ.smbcloud-cli
2 +PackageIdentifier: smbCloud.CLI
3 PackageVersion: @VERSION@
4 DefaultLocale: en-US
5 ManifestType: version