From 83cf1916e7d2fce09489baac69993f77f1fa0b51 Mon Sep 17 00:00:00 2001 From: Ben Chatelain Date: Thu, 3 Feb 2022 19:56:53 -0700 Subject: [PATCH 1/9] =?UTF-8?q?=F0=9F=91=BD=20Update=20path=20to=20release?= =?UTF-8?q?=20artifacts?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- script/install | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/install b/script/install index 7bb2379..1b72f39 100755 --- a/script/install +++ b/script/install @@ -23,7 +23,7 @@ fi while test -n "$1"; do if [[ "$1" == '--universal' ]]; then ARCH=universal - RELEASE=.build/apple/Products/Release + RELEASE=.build/release else # Override default prefix path with optional arg PREFIX="$1" From 3c6646aabfe453ed1accf34517912d4717e1c643 Mon Sep 17 00:00:00 2001 From: Ben Chatelain Date: Thu, 3 Feb 2022 19:57:11 -0700 Subject: [PATCH 2/9] =?UTF-8?q?=F0=9F=94=A8=20Add=20make=20target=20depend?= =?UTF-8?q?encies?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index b5088bc..d9d9496 100644 --- a/Makefile +++ b/Makefile @@ -110,11 +110,11 @@ bottles: bottle: bottles .PHONY: package -package: +package: build script/package .PHONY: packageInstall -packageInstall: +packageInstall: package script/package_install .PHONY: describe From 33c696c75afdb887009028dea20d86a69dfee753 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 2 Mar 2022 12:27:20 +0000 Subject: [PATCH 3/9] :arrow_up:(deps): Bump actions/checkout from 2 to 3 Bumps [actions/checkout](https://github.com/actions/checkout) from 2 to 3. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v2...v3) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/build-test.yml | 2 +- .github/workflows/danger.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index 6805623..4ff503c 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -38,7 +38,7 @@ jobs: steps: # https://github.com/actions/checkout#usage - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 with: # A fetch-depth of 0 includes all history and tags for script/version fetch-depth: 0 diff --git a/.github/workflows/danger.yml b/.github/workflows/danger.yml index cece6df..cc6838d 100644 --- a/.github/workflows/danger.yml +++ b/.github/workflows/danger.yml @@ -7,7 +7,7 @@ jobs: name: Danger runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Danger # https://github.com/orgs/danger/packages/container/package/danger-swift uses: docker://ghcr.io/danger/danger-swift:3.12.3 From 4c15cb6a71daec389f0045636a5700b9b5e0ca33 Mon Sep 17 00:00:00 2001 From: Jan Brasna <1784648+janbrasna@users.noreply.github.com> Date: Mon, 2 May 2022 18:47:27 +0200 Subject: [PATCH 4/9] Fix error message wording --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index aa07dd8..43f2530 100644 --- a/README.md +++ b/README.md @@ -205,7 +205,7 @@ apps, and is not yet able to install or update them. [#321](https://github.com/m If you see this error, it's probably because you haven't installed the app through the App Store yet. See [#46](https://github.com/mas-cli/mas/issues/46#issuecomment-248581233). -> This redownload is not available for this Apple ID either because it was bought by a different user of the +> This redownload is not available for this Apple ID either because it was bought by a different user or the > item was refunded or cancelled. If `mas` doesn't work for you as expected (e.g. you can't update/download apps), run `mas reset` and try again. From a484154d6cd1bd03a7e9eb67b418ac2a29984200 Mon Sep 17 00:00:00 2001 From: Ben Chatelain Date: Mon, 4 Jul 2022 15:08:22 -0600 Subject: [PATCH 5/9] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20Update=20brew=20tools?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Brewfile.lock.json | 68 +++++++++++++++++++++++----------------------- 1 file changed, 34 insertions(+), 34 deletions(-) diff --git a/Brewfile.lock.json b/Brewfile.lock.json index 3548ed2..093e70e 100644 --- a/Brewfile.lock.json +++ b/Brewfile.lock.json @@ -2,15 +2,15 @@ "entries": { "brew": { "markdownlint-cli": { - "version": "0.30.0", + "version": "0.31.1", "bottle": { "rebuild": 0, "root_url": "https://ghcr.io/v2/homebrew/core", "files": { "all": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/markdownlint-cli/blobs/sha256:8ada1bd40ab7ddd6566099ef74f8930ef1d8c4ce526e3f4d2619cfbd7e3651a4", - "sha256": "8ada1bd40ab7ddd6566099ef74f8930ef1d8c4ce526e3f4d2619cfbd7e3651a4" + "url": "https://ghcr.io/v2/homebrew/core/markdownlint-cli/blobs/sha256:26519a6a4330fd29cd897e61f8af2070def21758b06517c136690a5404d07d5a", + "sha256": "26519a6a4330fd29cd897e61f8af2070def21758b06517c136690a5404d07d5a" } } } @@ -55,74 +55,74 @@ } }, "shfmt": { - "version": "3.4.2", + "version": "3.5.1", "bottle": { "rebuild": 0, "root_url": "https://ghcr.io/v2/homebrew/core", "files": { "arm64_monterey": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:3d16adb18028a2bf572104d383a081d513ec3c608e2ea9dfd44fccf20c1e7b0f", - "sha256": "3d16adb18028a2bf572104d383a081d513ec3c608e2ea9dfd44fccf20c1e7b0f" + "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:633116b598a60ad576a79753208e13388f6a2460139c8aca44e5a25befdb017c", + "sha256": "633116b598a60ad576a79753208e13388f6a2460139c8aca44e5a25befdb017c" }, "arm64_big_sur": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:3eaff57d43b2b12b276a866e693fc76597091b6580b484cb27beb0f5b7a30f43", - "sha256": "3eaff57d43b2b12b276a866e693fc76597091b6580b484cb27beb0f5b7a30f43" + "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:1b0653c0a44f7db5e78c5c6d67de534a52c4f588fb65e3acbb8211d06b871bd9", + "sha256": "1b0653c0a44f7db5e78c5c6d67de534a52c4f588fb65e3acbb8211d06b871bd9" }, "monterey": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:b4508d0a67b4a5802fa2cb9875687ec933c2369395521b23b89faf4e7eb53cad", - "sha256": "b4508d0a67b4a5802fa2cb9875687ec933c2369395521b23b89faf4e7eb53cad" + "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:e7168603f81cf1357c2460c5c476fa66bf5421183d4dedeafe9cf38550fe8855", + "sha256": "e7168603f81cf1357c2460c5c476fa66bf5421183d4dedeafe9cf38550fe8855" }, "big_sur": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:b6765390c7387bb16bfa4fb63bb75bedf346bd2f42e70b2042c88230e668bd70", - "sha256": "b6765390c7387bb16bfa4fb63bb75bedf346bd2f42e70b2042c88230e668bd70" + "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:0e0683566d83cceecd4d02596e3c899a640918ff067b6e15e10f8aee424f1759", + "sha256": "0e0683566d83cceecd4d02596e3c899a640918ff067b6e15e10f8aee424f1759" }, "catalina": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:ab7bb4cf991a41eecda3fca4bef473dd711a62b89d906f3861515b8ec1386c98", - "sha256": "ab7bb4cf991a41eecda3fca4bef473dd711a62b89d906f3861515b8ec1386c98" + "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:4fabb118ba0da244f2b0ffe280b28e343712fac23e738ddf1db29fad68526d73", + "sha256": "4fabb118ba0da244f2b0ffe280b28e343712fac23e738ddf1db29fad68526d73" }, "x86_64_linux": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:8ed1ad0c691990dd7bc6bc1665f5c47f6815b73ad28e7d97bce07af69b28f962", - "sha256": "8ed1ad0c691990dd7bc6bc1665f5c47f6815b73ad28e7d97bce07af69b28f962" + "url": "https://ghcr.io/v2/homebrew/core/shfmt/blobs/sha256:faa60f70812132e10f94477676499a1e2bacb0d06fbe437e8480a997695c2203", + "sha256": "faa60f70812132e10f94477676499a1e2bacb0d06fbe437e8480a997695c2203" } } } }, "swiftformat": { - "version": "0.49.1", + "version": "0.49.9", "bottle": { "rebuild": 0, "root_url": "https://ghcr.io/v2/homebrew/core", "files": { "arm64_monterey": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/swiftformat/blobs/sha256:c43caffb4d2cf9546b0a8fa732ffe5d95b1b1fd7ab03f1c5da39c8e7a0e8ecb4", - "sha256": "c43caffb4d2cf9546b0a8fa732ffe5d95b1b1fd7ab03f1c5da39c8e7a0e8ecb4" + "url": "https://ghcr.io/v2/homebrew/core/swiftformat/blobs/sha256:bacd0dc8f488fd7909252467eaf16dcd339468857aea13a3643f7e0efd7715f8", + "sha256": "bacd0dc8f488fd7909252467eaf16dcd339468857aea13a3643f7e0efd7715f8" }, "arm64_big_sur": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/swiftformat/blobs/sha256:ad0ce5fc15fe1d339d366ece18694fdc1d14021684462a126ed20b537a1a9bf5", - "sha256": "ad0ce5fc15fe1d339d366ece18694fdc1d14021684462a126ed20b537a1a9bf5" + "url": "https://ghcr.io/v2/homebrew/core/swiftformat/blobs/sha256:7bc39a57d110f727993aa556cca5cba5549d536367bc12f25b56e25c4fdfa194", + "sha256": "7bc39a57d110f727993aa556cca5cba5549d536367bc12f25b56e25c4fdfa194" }, "monterey": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/swiftformat/blobs/sha256:33652b8015d31dbe45e00bdc598f1b228cb63c7083b90137fdec66318a88010f", - "sha256": "33652b8015d31dbe45e00bdc598f1b228cb63c7083b90137fdec66318a88010f" + "url": "https://ghcr.io/v2/homebrew/core/swiftformat/blobs/sha256:739d230372dd797d5cf5a0586156068ecb5965878550a67b5ca56ccdf2799557", + "sha256": "739d230372dd797d5cf5a0586156068ecb5965878550a67b5ca56ccdf2799557" }, "big_sur": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/swiftformat/blobs/sha256:f0ad88e5594a6a3e5a35834a9a22473a05511375942dbb046d1085cc537d60b8", - "sha256": "f0ad88e5594a6a3e5a35834a9a22473a05511375942dbb046d1085cc537d60b8" + "url": "https://ghcr.io/v2/homebrew/core/swiftformat/blobs/sha256:22080bdc75b03f5926d68fb248fc401d6a94876205ce03663a8950644b0e41e6", + "sha256": "22080bdc75b03f5926d68fb248fc401d6a94876205ce03663a8950644b0e41e6" }, "catalina": { "cellar": ":any_skip_relocation", - "url": "https://ghcr.io/v2/homebrew/core/swiftformat/blobs/sha256:564f5daf9cd82407843aed590bd4190f3e5aaa73a30b3bc8ae07135f1319ac97", - "sha256": "564f5daf9cd82407843aed590bd4190f3e5aaa73a30b3bc8ae07135f1319ac97" + "url": "https://ghcr.io/v2/homebrew/core/swiftformat/blobs/sha256:d4cda88cf3bef7b18e960197b8db4826f234e3b3434ba902c3924c37b9040fe8", + "sha256": "d4cda88cf3bef7b18e960197b8db4826f234e3b3434ba902c3924c37b9040fe8" } } } @@ -130,12 +130,12 @@ }, "tap": { "peripheryapp/periphery": { - "revision": "3b6699d53841e642169dc64e1acef1397806a081" + "revision": "020a0b79994d454dbc8dbd886009137fd741b836" } }, "cask": { "periphery": { - "version": "2.8.3", + "version": "2.9.0", "options": { "full_name": "periphery" } @@ -145,12 +145,12 @@ "system": { "macos": { "monterey": { - "HOMEBREW_VERSION": "3.3.9-36-ge970bb1", + "HOMEBREW_VERSION": "3.5.3-75-g39c9e2d", "HOMEBREW_PREFIX": "/opt/homebrew", - "Homebrew/homebrew-core": "f2b69fcaf6cf9925caac56dad26d39d30e89b42c", - "CLT": "13.2.0.0.1.1638488800", - "Xcode": "13.2.1", - "macOS": "12.1" + "Homebrew/homebrew-core": "00e5383db36fddc6b26df896229289b42462e63e", + "CLT": "13.4.0.0.1.1651278267", + "Xcode": "13.4.1", + "macOS": "12.4" } } } From 5707750eeb599b009ad40739bafa06e0a866eb38 Mon Sep 17 00:00:00 2001 From: Ben Chatelain Date: Mon, 4 Jul 2022 15:08:46 -0600 Subject: [PATCH 6/9] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20swift-format=20(releas?= =?UTF-8?q?e/5.6)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Package.resolved | 30 ++++++++++++++++++++++++------ Package.swift | 7 ++++++- 2 files changed, 30 insertions(+), 7 deletions(-) diff --git a/Package.resolved b/Package.resolved index bea10ba..ef2401b 100644 --- a/Package.resolved +++ b/Package.resolved @@ -60,16 +60,16 @@ "repositoryURL": "https://github.com/apple/swift-argument-parser.git", "state": { "branch": null, - "revision": "e1465042f195f374b94f915ba8ca49de24300a0d", - "version": "1.0.2" + "revision": "df9ee6676cd5b3bf5b330ec7568a5644f547201b", + "version": "1.1.3" } }, { "package": "swift-format", "repositoryURL": "https://github.com/apple/swift-format", "state": { - "branch": "swift-5.5-branch", - "revision": "f872223e16742fd97fabd319fbf4a939230cc796", + "branch": "release/5.6", + "revision": "e6b8c60c7671066d229e30efa1e31acf57be412e", "version": null } }, @@ -78,8 +78,26 @@ "repositoryURL": "https://github.com/apple/swift-syntax", "state": { "branch": null, - "revision": "75e60475d9d8fd5bbc16a12e0eaa2cb01b0c322e", - "version": "0.50500.0" + "revision": "0b6c22b97f8e9320bca62e82cdbee601cf37ad3f", + "version": "0.50600.1" + } + }, + { + "package": "swift-system", + "repositoryURL": "https://github.com/apple/swift-system.git", + "state": { + "branch": null, + "revision": "836bc4557b74fe6d2660218d56e3ce96aff76574", + "version": "1.1.1" + } + }, + { + "package": "swift-tools-support-core", + "repositoryURL": "https://github.com/apple/swift-tools-support-core.git", + "state": { + "branch": null, + "revision": "b7667f3e266af621e5cc9c77e74cacd8e8c00cb4", + "version": "0.2.5" } }, { diff --git a/Package.swift b/Package.swift index 404a534..2918211 100644 --- a/Package.swift +++ b/Package.swift @@ -70,7 +70,12 @@ let package = Package( swiftLanguageVersions: [.v5] ) -#if compiler(>=5.5) +// https://github.com/apple/swift-format#matching-swift-format-to-your-swift-version +#if compiler(>=5.6) + package.dependencies += [ + .package(url: "https://github.com/apple/swift-format", .branch("release/5.6")) + ] +#elseif compiler(>=5.5) package.dependencies += [ .package(url: "https://github.com/apple/swift-format", .branch("swift-5.5-branch")) ] From f3ef215900fd6e22ccadf4a573ec0b6b8ec3524f Mon Sep 17 00:00:00 2001 From: Ben Chatelain Date: Mon, 4 Jul 2022 17:29:01 -0600 Subject: [PATCH 7/9] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20Swift=20(5.6.1)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .swift-version | 2 +- Makefile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.swift-version b/.swift-version index 84197c8..b7c7542 100644 --- a/.swift-version +++ b/.swift-version @@ -1 +1 @@ -5.3.2 +5.6.1 diff --git a/Makefile b/Makefile index d9d9496..123a90c 100644 --- a/Makefile +++ b/Makefile @@ -19,7 +19,7 @@ PREFIX ?= /usr/local # Swift 5.3 # SWIFT_VERSION = swift-5.3-DEVELOPMENT-SNAPSHOT-2020-04-21-a -SWIFT_VERSION = 5.3.2 +SWIFT_VERSION = 5.6.1 # set EXECUTABLE_DIRECTORY according to your specific environment # run swift build and see where the output executable is created From dc4b5f55e2181d472a4d757c7c3794437e1fabc3 Mon Sep 17 00:00:00 2001 From: Ben Chatelain Date: Mon, 4 Jul 2022 17:29:28 -0600 Subject: [PATCH 8/9] =?UTF-8?q?=F0=9F=8E=AF=20Add=20help=20make=20target?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Makefile | 64 +++++++++++++++++++++++++++++++++----------------------- 1 file changed, 38 insertions(+), 26 deletions(-) diff --git a/Makefile b/Makefile index 123a90c..2c739ba 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,6 @@ # mas # - ################################################################################ # # Variables @@ -33,46 +32,60 @@ PLATFORM = $(ARCH)-apple-macosx EXECUTABLE_DIRECTORY = ./.build/${PLATFORM}/debug endif +################################################################################ +# +# Help +# + +.DEFAULT_GOAL := help + +.PHONY: help +help: MAKEFILE_FMT = " \033[36m%-25s\033[0m%s\n" +help: ## (default) Displays this message + @echo "Ditto main Makefile." + @echo "" + @echo "Targets:" + @grep -E '^[a-zA-Z0-9_-]*:.*?##' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?##"}; {printf $(MAKEFILE_FMT), $$1, $$2}' + @echo "" + @echo "Parameters:" + @grep -E '^[A-Z0-9_-]* ?\?=.*?##' $(MAKEFILE_LIST) | awk 'BEGIN {FS = " ?\\?=.*?##"}; {printf $(MAKEFILE_FMT), $$1, $$2}' +: # Hacky way to display a newline ## ################################################################################ # # Targets # -# Prints versions of tools used by this Makefile. .PHONY: version -version: +version: ## Prints versions of tools used by this Makefile. xcodebuild -version swiftenv version swift --version swift package tools-version .PHONY: init -init: +init: ## Installs tools. - swiftenv install $(SWIFT_VERSION) swiftenv local $(SWIFT_VERSION) .PHONY: bootstrap -bootstrap: +bootstrap: ## Installs tools. script/bootstrap .PHONY: clean -clean: +clean: ## Cleans built products. script/clean -.PHONY: distclean -distclean: clean - .PHONY: updateHeaders -updateHeaders: +updateHeaders: ## Updates private headers. script/update_headers .PHONY: build -build: +build: ## Builds the project. script/build .PHONY: test -test: build +test: build ## Runs tests. script/test # make run ARGS="asdf" @@ -81,54 +94,53 @@ run: build ${EXECUTABLE_DIRECTORY}/${CMD_NAME} $(ARGS) .PHONY: install -install: +install: ## Installs the project. script/install $(PREFIX) .PHONY: uninstall -uninstall: +uninstall: ## Uninstalls the project. script/uninstall .PHONY: format -format: +format: ## Formats source code. script/format .PHONY: lint -lint: +lint: ## Lints source code. script/lint .PHONY: danger -danger: +danger: ## Runs danger. script/danger # Builds bottles .PHONY: bottles -bottles: +bottles: ## Builds bottles. script/bottle -# Alias for bottles .PHONY: bottle -bottle: bottles +bottle: bottles ## Alias for bottles .PHONY: package -package: build +package: build ## Packages the project. script/package .PHONY: packageInstall -packageInstall: package +packageInstall: package ## Installs the package. script/package_install .PHONY: describe -describe: +describe: ## Describes the Swift package. swift package describe .PHONY: resolve -resolve: +resolve: ## Resolves SwiftPM dependencies. swift package resolve .PHONY: dependencies -dependencies: resolve +dependencies: resolve ## Lists SwiftPM dependencies. swift package show-dependencies .PHONY: update -update: resolve +update: resolve ## Updates SwiftPM dependencies. swift package update From 6cc248b83ebaa0640d0dc45436e9a25e3058a475 Mon Sep 17 00:00:00 2001 From: Ben Chatelain Date: Mon, 4 Jul 2022 17:29:51 -0600 Subject: [PATCH 9/9] =?UTF-8?q?=F0=9F=9A=A8=20FIx=20lint=20warning=20with?= =?UTF-8?q?=20new=20#unavailable?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Sources/MasKit/AppStore/Downloader.swift | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Sources/MasKit/AppStore/Downloader.swift b/Sources/MasKit/AppStore/Downloader.swift index 2b5ab14..650229d 100644 --- a/Sources/MasKit/AppStore/Downloader.swift +++ b/Sources/MasKit/AppStore/Downloader.swift @@ -64,11 +64,10 @@ private func downloadWithRetries( /// - Returns: A promise the completes when the download is complete. private func download(_ appID: UInt64, purchase: Bool = false) -> Promise { var storeAccount: ISStoreAccount? - if #available(macOS 12, *) { + if #unavailable(macOS 12) { // Monterey obscured the user's account information, but still allows // redownloads without passing it to SSPurchase. // https://github.com/mas-cli/mas/issues/417 - } else { guard let account = ISStoreAccount.primaryAccount else { return Promise(error: MASError.notSignedIn) }