From 73ba1dd305e5041dc96b6780d58f3d6649921556 Mon Sep 17 00:00:00 2001 From: Dave Verwer Date: Thu, 5 Dec 2024 19:26:04 +0000 Subject: [PATCH 1/2] Gate the custom collection metadata to staging until the blog post is live. --- Sources/App/Views/PackageController/GetRoute.Model+ext.swift | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Sources/App/Views/PackageController/GetRoute.Model+ext.swift b/Sources/App/Views/PackageController/GetRoute.Model+ext.swift index 0c251667c..db88af843 100644 --- a/Sources/App/Views/PackageController/GetRoute.Model+ext.swift +++ b/Sources/App/Views/PackageController/GetRoute.Model+ext.swift @@ -399,6 +399,10 @@ extension API.PackageController.GetRoute.Model { } func customCollectionsListItem() -> Node { + @Dependency(\.environment) var environment + guard environment.current() == .development + else { return .empty } + guard customCollections.isEmpty == false else { return .empty } From cc519fe78a7e08ee9f6437dd2ea221fd8729d87c Mon Sep 17 00:00:00 2001 From: Dave Verwer Date: Thu, 5 Dec 2024 19:30:49 +0000 Subject: [PATCH 2/2] Snapshots. --- .../test_PackageShowView_customCollection.1.html | 3 --- 1 file changed, 3 deletions(-) diff --git a/Tests/AppTests/__Snapshots__/WebpageSnapshotTests/test_PackageShowView_customCollection.1.html b/Tests/AppTests/__Snapshots__/WebpageSnapshotTests/test_PackageShowView_customCollection.1.html index 74d1c725a..166893c3a 100644 --- a/Tests/AppTests/__Snapshots__/WebpageSnapshotTests/test_PackageShowView_customCollection.1.html +++ b/Tests/AppTests/__Snapshots__/WebpageSnapshotTests/test_PackageShowView_customCollection.1.html @@ -162,9 +162,6 @@

When working with a Swift Package Manager manifest:

5 open pull requests. The last issue was closed 5 days ago and the last pull request was merged/closed 6 days ago.
  • This package depends on 2 other packages.
  • -
  • Member of the - Custom Collection collection. -
  • licensed
  • 17 stars
  • 3 libraries