Skip to content

Commit 4fc9c92

Browse files
committed
wip: move packages to 'swift-web' repository
1 parent 246b0b6 commit 4fc9c92

File tree

10 files changed

+22
-548
lines changed

10 files changed

+22
-548
lines changed

Package.resolved

Lines changed: 12 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Package.swift

Lines changed: 8 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -13,31 +13,19 @@ let package = Package(
1313
.package(url: "https://github.com/sliemeobn/elementary.git", exact: "0.4.3"),
1414
.package(url: "https://github.com/pointfreeco/swift-url-routing.git", exact: "0.6.2"),
1515
.package(url: "https://github.com/pointfreeco/swift-dependencies.git", exact: "1.6.2"),
16+
.package(url: "https://github.com/swiftlang/swift-markdown.git", revision: "e62a44fd1f2764ba8807db3b6f257627449bbb8c"),
1617
.package(url: "https://github.com/errorerrorerror/swift-cascadia", revision: "a13dfd0a3818c8f9368bbd4aeb3c6607f68838bd"),
17-
.package(url: "https://github.com/swiftlang/swift-markdown.git", revision: "e62a44fd1f2764ba8807db3b6f257627449bbb8c")
18+
.package(url: "https://github.com/errorerrorerror/swift-web.git", exact: "0.0.3")
1819
],
1920
targets: [
20-
.executableTarget(
21-
name: "AssetGenCLI",
22-
dependencies: [
23-
.product(name: "ArgumentParser", package: "swift-argument-parser")
24-
]
25-
),
26-
.plugin(
27-
name: "AssetGenPlugin",
28-
capability: .buildTool(),
29-
dependencies: [
30-
.target(name: "AssetGenCLI")
31-
]
32-
),
3321
.target(
3422
name: "PublicAssets",
3523
dependencies: [
3624
.product(name: "Dependencies", package: "swift-dependencies"),
3725
.product(name: "DependenciesMacros", package: "swift-dependencies"),
3826
],
3927
resources: [.copy("assets")],
40-
plugins: ["AssetGenPlugin"]
28+
plugins: [.plugin(name: "TypedAssetsPlugin", package: "swift-web")]
4129
),
4230
.target(
4331
name: "Models",
@@ -58,9 +46,10 @@ let package = Package(
5846
"Models",
5947
"ActivityClient",
6048
.product(name: "Dependencies", package: "swift-dependencies"),
61-
.product(name: "URLRouting", package: "swift-url-routing"),
6249
.product(name: "Hummingbird", package: "hummingbird"),
6350
.product(name: "HummingbirdRouter", package: "hummingbird"),
51+
.product(name: "URLRouting", package: "swift-url-routing"),
52+
.product(name: "HummingbirdURLRouting", package: "swift-web")
6453
]
6554
),
6655
.target(
@@ -89,9 +78,9 @@ let package = Package(
8978
.product(name: "Dependencies", package: "swift-dependencies"),
9079
.product(name: "Hummingbird", package: "hummingbird"),
9180
.product(name: "HummingbirdRouter", package: "hummingbird"),
92-
.product(name: "ArgumentParser", package: "swift-argument-parser")
93-
],
94-
resources: [.embedInCode("Resources")]
81+
.product(name: "ArgumentParser", package: "swift-argument-parser"),
82+
.product(name: "MiddlewareUtils", package: "swift-web")
83+
]
9584
),
9685
],
9786
swiftLanguageModes: [.v6]

Plugins/AssetGenPlugin/AssetGenPlugin.swift

Lines changed: 0 additions & 32 deletions
This file was deleted.

Sources/App/Middlewares/ReloadBrowserMiddleware.swift

Lines changed: 0 additions & 69 deletions
This file was deleted.

Sources/App/Middlewares/SiteMiddleware.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import Dependencies
33
import class Foundation.JSONEncoder
44
import Hummingbird
55
import HummingbirdRouter
6+
import MiddlewareUtils
67
import Pages
78
import PublicAssets
89
import Routes

Sources/App/Resources/liveServerSnippet.html

Lines changed: 0 additions & 37 deletions
This file was deleted.

Sources/App/Utils/Auth.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import Hummingbird
22
import Foundation
33
import Dependencies
44
import Parsing
5+
import HummingbirdURLRouting
56

67
extension HTTPFields.Authorization {
78
func validate() throws {

0 commit comments

Comments
 (0)