Compare commits

...

10 Commits

Author SHA1 Message Date
8ea67b9a8c Merge pull request #2 from smparkin/dependabot/swift/github.com/apple/swift-nio-http2-1.38.0
Bump github.com/apple/swift-nio-http2 from 1.36.0 to 1.38.0
2025-08-13 19:09:59 -07:00
dependabot[bot]
9ec0447b84 Bump github.com/apple/swift-nio-http2 from 1.36.0 to 1.38.0
Bumps [github.com/apple/swift-nio-http2](https://github.com/apple/swift-nio-http2) from 1.36.0 to 1.38.0.
- [Release notes](https://github.com/apple/swift-nio-http2/releases)
- [Commits](https://github.com/apple/swift-nio-http2/compare/1.36.0...1.38.0)

---
updated-dependencies:
- dependency-name: github.com/apple/swift-nio-http2
  dependency-version: 1.38.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-13 23:59:52 +00:00
75eddcb6fd Update to swift 6 2025-05-12 19:45:46 -07:00
704ca27cd7 Fix github link 2025-02-08 12:30:06 -08:00
4b694fed62 Add tesla well known 2025-01-26 17:28:38 -08:00
f9c244e392 fix docker-compose 2024-10-28 21:57:27 -07:00
bd524f13b2 bump deps 2024-07-05 10:21:55 -07:00
07a19be4b3 switch back to docker 2024-07-05 10:09:18 -07:00
261b9686bc dark mode website 2024-05-14 21:02:58 -07:00
679b748b2f update deps 2024-02-20 23:29:52 -08:00
39 changed files with 578 additions and 900 deletions

2
.gitignore vendored Normal file
View File

@@ -0,0 +1,2 @@
.vscode
.build

View File

@@ -10,5 +10,18 @@
<integer>0</integer> <integer>0</integer>
</dict> </dict>
</dict> </dict>
<key>SuppressBuildableAutocreation</key>
<dict>
<key>AppTests</key>
<dict>
<key>primary</key>
<true/>
</dict>
<key>Run</key>
<dict>
<key>primary</key>
<true/>
</dict>
</dict>
</dict> </dict>
</plist> </plist>

77
Dockerfile Normal file
View File

@@ -0,0 +1,77 @@
# ================================
# Build image
# ================================
FROM swift:6.1.0-noble AS build
# Install OS updates and, if needed, sqlite3
RUN export DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true \
&& apt-get -q update \
&& apt-get -q dist-upgrade -y\
&& rm -rf /var/lib/apt/lists/*
# Set up a build area
WORKDIR /build
# First just resolve dependencies.
# This creates a cached layer that can be reused
# as long as your Package.swift/Package.resolved
# files do not change.
COPY ./Package.* ./
RUN swift package resolve
# Copy entire repo into container
COPY . .
# Build everything, with optimizations
RUN swift build -c release --static-swift-stdlib
# Switch to the staging area
WORKDIR /staging
# Copy main executable to staging area
RUN cp "$(swift build --package-path /build -c release --show-bin-path)/Run" ./
# Copy resources bundled by SPM to staging area
RUN find -L "$(swift build --package-path /build -c release --show-bin-path)/" -regex '.*\.resources$' -exec cp -Ra {} ./ \;
# Copy any resources from the public directory and views directory if the directories exist
# Ensure that by default, neither the directory nor any of its contents are writable.
RUN [ -d /build/Public ] && { mv /build/Public ./Public && chmod -R a-w ./Public; } || true
RUN [ -d /build/Resources ] && { mv /build/Resources ./Resources && chmod -R a-w ./Resources; } || true
# ================================
# Run image
# ================================
FROM ubuntu:noble
# Make sure all system packages are up to date, and install only essential packages.
RUN export DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true \
&& apt-get -q update \
&& apt-get -q dist-upgrade -y \
&& apt-get -q install -y \
ca-certificates \
tzdata \
# If your app or its dependencies import FoundationNetworking, also install `libcurl4`.
# libcurl4 \
# If your app or its dependencies import FoundationXML, also install `libxml2`.
# libxml2 \
&& rm -r /var/lib/apt/lists/*
# Create a vapor user and group with /app as its home directory
RUN useradd --user-group --create-home --system --skel /dev/null --home-dir /app vapor
# Switch to the new home directory
WORKDIR /app
# Copy built executable and any staged resources from builder
COPY --from=build --chown=vapor:vapor /staging /app
# Ensure all further commands run as the vapor user
USER vapor:vapor
# Let Docker bind to port 8080
EXPOSE 8080
# Start the Vapor service when the image is run, default to listening on 8080 in production environment
ENTRYPOINT ["./Run"]
CMD ["serve", "--env", "production", "--hostname", "0.0.0.0", "--port", "8080"]

249
Package.resolved Normal file
View File

@@ -0,0 +1,249 @@
{
"originHash" : "6a244abdea5ff1ff36734246a0ac5fbc6830084dfc1322e83f9683689f7bb3fc",
"pins" : [
{
"identity" : "async-http-client",
"kind" : "remoteSourceControl",
"location" : "https://github.com/swift-server/async-http-client.git",
"state" : {
"revision" : "3b265e6a00fc5c3fdb8f91f773e506990c704337",
"version" : "1.26.0"
}
},
{
"identity" : "async-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/async-kit.git",
"state" : {
"revision" : "e048c8ee94967e8d8a1c2ec0e1156d6f7fa34d31",
"version" : "1.20.0"
}
},
{
"identity" : "console-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/console-kit.git",
"state" : {
"revision" : "742f624a998cba2a9e653d9b1e91ad3f3a5dff6b",
"version" : "4.15.2"
}
},
{
"identity" : "leaf",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/leaf.git",
"state" : {
"revision" : "d469584b9186851c5a4012d11325fb9db3207ebb",
"version" : "4.5.0"
}
},
{
"identity" : "leaf-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/leaf-kit.git",
"state" : {
"revision" : "cf186d8f2ef33e16fd1dd78df36466c22c2e632f",
"version" : "1.13.1"
}
},
{
"identity" : "multipart-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/multipart-kit.git",
"state" : {
"revision" : "3498e60218e6003894ff95192d756e238c01f44e",
"version" : "4.7.1"
}
},
{
"identity" : "routing-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/routing-kit.git",
"state" : {
"revision" : "93f7222c8e195cbad39fafb5a0e4cc85a8def7ea",
"version" : "4.9.2"
}
},
{
"identity" : "swift-algorithms",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-algorithms.git",
"state" : {
"revision" : "87e50f483c54e6efd60e885f7f5aa946cee68023",
"version" : "1.2.1"
}
},
{
"identity" : "swift-asn1",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-asn1.git",
"state" : {
"revision" : "a54383ada6cecde007d374f58f864e29370ba5c3",
"version" : "1.3.2"
}
},
{
"identity" : "swift-atomics",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-atomics.git",
"state" : {
"revision" : "cd142fd2f64be2100422d658e7411e39489da985",
"version" : "1.2.0"
}
},
{
"identity" : "swift-collections",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-collections.git",
"state" : {
"revision" : "671108c96644956dddcd89dd59c203dcdb36cec7",
"version" : "1.1.4"
}
},
{
"identity" : "swift-crypto",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-crypto.git",
"state" : {
"revision" : "e8d6eba1fef23ae5b359c46b03f7d94be2f41fed",
"version" : "3.12.3"
}
},
{
"identity" : "swift-distributed-tracing",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-distributed-tracing.git",
"state" : {
"revision" : "a64a0abc2530f767af15dd88dda7f64d5f1ff9de",
"version" : "1.2.0"
}
},
{
"identity" : "swift-http-structured-headers",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-http-structured-headers.git",
"state" : {
"revision" : "f280fc7676b9940ff2c6598642751ea333c6544f",
"version" : "1.2.2"
}
},
{
"identity" : "swift-http-types",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-http-types.git",
"state" : {
"revision" : "a0a57e949a8903563aba4615869310c0ebf14c03",
"version" : "1.4.0"
}
},
{
"identity" : "swift-log",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-log.git",
"state" : {
"revision" : "3d8596ed08bd13520157f0355e35caed215ffbfa",
"version" : "1.6.3"
}
},
{
"identity" : "swift-metrics",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-metrics.git",
"state" : {
"revision" : "4c83e1cdf4ba538ef6e43a9bbd0bcc33a0ca46e3",
"version" : "2.7.0"
}
},
{
"identity" : "swift-nio",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio.git",
"state" : {
"revision" : "34d486b01cd891297ac615e40d5999536a1e138d",
"version" : "2.83.0"
}
},
{
"identity" : "swift-nio-extras",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-extras.git",
"state" : {
"revision" : "f1f6f772198bee35d99dd145f1513d8581a54f2c",
"version" : "1.26.0"
}
},
{
"identity" : "swift-nio-http2",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-http2.git",
"state" : {
"revision" : "5e9e99ec96c53bc2c18ddd10c1e25a3cd97c55e5",
"version" : "1.38.0"
}
},
{
"identity" : "swift-nio-ssl",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-ssl.git",
"state" : {
"revision" : "4b38f35946d00d8f6176fe58f96d83aba64b36c7",
"version" : "2.31.0"
}
},
{
"identity" : "swift-nio-transport-services",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-transport-services.git",
"state" : {
"revision" : "cd1e89816d345d2523b11c55654570acd5cd4c56",
"version" : "1.24.0"
}
},
{
"identity" : "swift-numerics",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-numerics.git",
"state" : {
"revision" : "e0ec0f5f3af6f3e4d5e7a19d2af26b481acb6ba8",
"version" : "1.0.3"
}
},
{
"identity" : "swift-service-context",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-service-context.git",
"state" : {
"revision" : "8946c930cae601452149e45d31d8ddfac973c3c7",
"version" : "1.2.0"
}
},
{
"identity" : "swift-system",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-system.git",
"state" : {
"revision" : "a34201439c74b53f0fd71ef11741af7e7caf01e1",
"version" : "1.4.2"
}
},
{
"identity" : "vapor",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/vapor.git",
"state" : {
"revision" : "87b0edd2633c35de543cb7573efe5fbf456181bc",
"version" : "4.114.1"
}
},
{
"identity" : "websocket-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/websocket-kit.git",
"state" : {
"revision" : "8666c92dbbb3c8eefc8008c9c8dcf50bfd302167",
"version" : "2.16.1"
}
}
],
"version" : 3
}

38
Package.swift Normal file
View File

@@ -0,0 +1,38 @@
// swift-tools-version:6.1.0
import PackageDescription
let package = Package(
name: "smparkin",
platforms: [
.macOS(.v13)
],
dependencies: [
.package(url: "https://github.com/vapor/vapor.git", .upToNextMajor(from: "4.114.0")),
.package(url: "https://github.com/vapor/leaf.git", .upToNextMajor(from: "4.5.0")),
],
targets: [
.target(
name: "App",
dependencies: [
.product(name: "Vapor", package: "vapor"),
.product(name: "Leaf", package: "leaf")
],
swiftSettings: [
.unsafeFlags(["-cross-module-optimization"], .when(configuration: .release))
]
),
.executableTarget(
name: "Run",
dependencies: [
.target(name: "App")
]
),
.testTarget(
name: "AppTests",
dependencies: [
.target(name: "App"),
.product(name: "XCTVapor", package: "vapor")
]
)
]
)

View File

@@ -0,0 +1,4 @@
-----BEGIN PUBLIC KEY-----
MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEHZR4mQ31/kYqSOc2CWN7iZVmF/6f
6Rg39BboB9K8ckj02PvNK/JheaOaQWYuNirsnfn1cGBmhE4k8p6hL2dLvQ==
-----END PUBLIC KEY-----

View File

Before

Width:  |  Height:  |  Size: 497 KiB

After

Width:  |  Height:  |  Size: 497 KiB

View File

Before

Width:  |  Height:  |  Size: 544 KiB

After

Width:  |  Height:  |  Size: 544 KiB

View File

Before

Width:  |  Height:  |  Size: 1.0 MiB

After

Width:  |  Height:  |  Size: 1.0 MiB

View File

Before

Width:  |  Height:  |  Size: 1.0 MiB

After

Width:  |  Height:  |  Size: 1.0 MiB

View File

Before

Width:  |  Height:  |  Size: 466 KiB

After

Width:  |  Height:  |  Size: 466 KiB

1
README.md Normal file
View File

@@ -0,0 +1 @@
smpark.in

109
Resources/Views/home.leaf Normal file
View File

@@ -0,0 +1,109 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Stephen Parkinson</title>
<style>
body {
margin: 0;
font-family: Arial, sans-serif;
background-color: #121212;
color: #ffffff;
}
header {
background-color: #1e1e1e;
padding: 20px;
text-align: center;
border-bottom: 2px solid #9370db !important;
}
header h1 {
margin: 0;
color: #9370db !important;
}
header img {
max-width: 150px;
height: auto;
border-radius: 50%;
border: 2px solid #9370db !important;
margin: 10px 0;
}
a:link,
a:visited {
color: #9370db !important;
text-decoration: none;
transition: background-color 0.3s, color 0.3s;
}
a:hover {
background-color: #9370db !important;
color: #ffffff !important;
}
a:active {
background-color: #9370db !important;
color: #ffffff !important;
}
section {
max-width: 800px;
margin: 40px auto;
padding: 20px;
background-color: #1e1e1e;
border-radius: 10px;
box-sizing: border-box;
}
section img {
max-width: 100%;
height: auto;
display: block;
margin: 0 auto 20px auto;
border-radius: 10px;
border: 2px solid #9370db !important;
}
footer {
text-align: center;
padding: 20px;
background-color: #1e1e1e;
border-top: 2px solid #9370db !important;
}
</style>
</head>
<body>
<header>
<img
src="/images/me.jpg"
alt="Stephen Parkinson"
/>
<h1>Stephen Parkinson</h1>
<p>Systems Development Engineer</p>
</header>
<section id="about">
<h2>About Me</h2>
<p>I'm doing a lot of stuff with computers right now.</p>
</section>
<section id="image">
<img
src="images/trees.jpg"
alt="Project Image"
/>
</section>
<section id="contact">
<h2>Contact</h2>
<p>
Connect with me on
<a
href="https://www.linkedin.com/in/stephen-parkinson"
target="_blank"
>LinkedIn</a
>.
</p>
<p>
Check out my work on
<a href="https://github.com/smparkin" target="_blank"
>GitHub</a
>.
</p>
</section>
<footer>
<p>&copy; 2024 Stephen Parkinson. All rights reserved.</p>
</footer>
</body>
</html>

View File

@@ -0,0 +1,15 @@
import Leaf
import Vapor
// Called before your application initializes.
public func configure(_ app: Application) throws {
//leaf
app.views.use(.leaf)
//Register middleware
app.middleware.use(FileMiddleware(publicDirectory: app.directory.publicDirectory))
app.middleware.use(ErrorMiddleware.default(environment: app.environment))
//routes
try routes(app)
}

18
Sources/Run/main.swift Normal file
View File

@@ -0,0 +1,18 @@
import App
import Vapor
import Logging
var env = try Environment.detect()
try LoggingSystem.bootstrap(from: &env)
let app = try await Application.make(env)
do {
try configure(app)
try await app.execute()
} catch {
app.logger.report(error: error)
try? await app.asyncShutdown()
throw error
}
try await app.asyncShutdown()

View File

@@ -0,0 +1,12 @@
import XCTest
@testable import App
class AppTests: XCTestCase {
func testStub() throws {
XCTAssert(true)
}
static let allTests = [
("testStub", testStub),
]
}

11
Tests/LinuxMain.swift Normal file
View File

@@ -0,0 +1,11 @@
#if os(Linux)
import XCTest
@testable import AppTests
XCTMain([
// AppTests
testCase(AppTests.allTests),
])
#endif

29
docker-compose.yml Normal file
View File

@@ -0,0 +1,29 @@
# Docker Compose file for Vapor
#
# Install Docker on your system to run and test
# your Vapor app in a production-like environment.
#
# Note: This file is intended for testing and does not
# implement best practices for a production deployment.
#
# Learn more: https://docs.docker.com/compose/reference/
#
# Build images: docker-compose build
# Start app: docker-compose up app
# Stop all: docker-compose down
#
version: '3.7'
x-shared_environment: &shared_environment
LOG_LEVEL: ${LOG_LEVEL:-debug}
services:
app:
image: sparkii/smparkin:latest
build:
context: .
environment:
<<: *shared_environment
ports:
- '8888:8888'
command: ["serve", "--env", "production", "--hostname", "0.0.0.0", "--port", "8888"]

View File

@@ -1,439 +0,0 @@
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 56;
objects = {
/* Begin PBXBuildFile section */
C041F2C22AB021E30011752C /* smparkinApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = C041F2C12AB021E30011752C /* smparkinApp.swift */; };
C041F2C42AB021E30011752C /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = C041F2C32AB021E30011752C /* ContentView.swift */; };
C041F2C62AB021E40011752C /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = C041F2C52AB021E40011752C /* Assets.xcassets */; };
C041F2C92AB021E40011752C /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = C041F2C82AB021E40011752C /* Preview Assets.xcassets */; };
C041F2D22AB0238F0011752C /* Vapor in Frameworks */ = {isa = PBXBuildFile; productRef = C041F2D12AB0238F0011752C /* Vapor */; };
C041F2D72AB023CA0011752C /* Leaf in Frameworks */ = {isa = PBXBuildFile; productRef = C041F2D62AB023CA0011752C /* Leaf */; };
C041F2DA2AB0243C0011752C /* Public in Resources */ = {isa = PBXBuildFile; fileRef = C041F2D82AB0243C0011752C /* Public */; };
C041F2DD2AB024510011752C /* Routes.swift in Sources */ = {isa = PBXBuildFile; fileRef = C041F2DC2AB024510011752C /* Routes.swift */; };
C041F2DF2AB0246C0011752C /* Server.swift in Sources */ = {isa = PBXBuildFile; fileRef = C041F2DE2AB0246C0011752C /* Server.swift */; };
C0C8E2BE2AB0304D00E809B4 /* home.leaf in Resources */ = {isa = PBXBuildFile; fileRef = C0C8E2BB2AB02B6C00E809B4 /* home.leaf */; };
C0C8E2BF2AB0304D00E809B4 /* privacy.leaf in Resources */ = {isa = PBXBuildFile; fileRef = C0C8E2BC2AB02B6C00E809B4 /* privacy.leaf */; };
C0C8E2C02AB0304D00E809B4 /* welcome.leaf in Resources */ = {isa = PBXBuildFile; fileRef = C0C8E2BD2AB02B6C00E809B4 /* welcome.leaf */; };
C0C8E2C12AB0304D00E809B4 /* 404.leaf in Resources */ = {isa = PBXBuildFile; fileRef = C0C8E2BA2AB02B6C00E809B4 /* 404.leaf */; };
C0C8E2C52AB03D6200E809B4 /* Log.swift in Sources */ = {isa = PBXBuildFile; fileRef = C0C8E2C42AB03D6200E809B4 /* Log.swift */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
C041F2BE2AB021E30011752C /* smparkin.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = smparkin.app; sourceTree = BUILT_PRODUCTS_DIR; };
C041F2C12AB021E30011752C /* smparkinApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = smparkinApp.swift; sourceTree = "<group>"; };
C041F2C32AB021E30011752C /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = "<group>"; };
C041F2C52AB021E40011752C /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
C041F2C82AB021E40011752C /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = "<group>"; };
C041F2D82AB0243C0011752C /* Public */ = {isa = PBXFileReference; lastKnownFileType = folder; path = Public; sourceTree = "<group>"; };
C041F2DC2AB024510011752C /* Routes.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Routes.swift; sourceTree = "<group>"; };
C041F2DE2AB0246C0011752C /* Server.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Server.swift; sourceTree = "<group>"; };
C0C8E2BA2AB02B6C00E809B4 /* 404.leaf */ = {isa = PBXFileReference; lastKnownFileType = text; path = 404.leaf; sourceTree = "<group>"; };
C0C8E2BB2AB02B6C00E809B4 /* home.leaf */ = {isa = PBXFileReference; lastKnownFileType = text; path = home.leaf; sourceTree = "<group>"; };
C0C8E2BC2AB02B6C00E809B4 /* privacy.leaf */ = {isa = PBXFileReference; lastKnownFileType = text; path = privacy.leaf; sourceTree = "<group>"; };
C0C8E2BD2AB02B6C00E809B4 /* welcome.leaf */ = {isa = PBXFileReference; lastKnownFileType = text; path = welcome.leaf; sourceTree = "<group>"; };
C0C8E2C42AB03D6200E809B4 /* Log.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Log.swift; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
C041F2BB2AB021E30011752C /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
C041F2D72AB023CA0011752C /* Leaf in Frameworks */,
C041F2D22AB0238F0011752C /* Vapor in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
C041F2B52AB021E30011752C = {
isa = PBXGroup;
children = (
C041F2C02AB021E30011752C /* smparkin */,
C041F2BF2AB021E30011752C /* Products */,
);
sourceTree = "<group>";
};
C041F2BF2AB021E30011752C /* Products */ = {
isa = PBXGroup;
children = (
C041F2BE2AB021E30011752C /* smparkin.app */,
);
name = Products;
sourceTree = "<group>";
};
C041F2C02AB021E30011752C /* smparkin */ = {
isa = PBXGroup;
children = (
C041F2C12AB021E30011752C /* smparkinApp.swift */,
C041F2C32AB021E30011752C /* ContentView.swift */,
C041F2DE2AB0246C0011752C /* Server.swift */,
C041F2DC2AB024510011752C /* Routes.swift */,
C0C8E2C42AB03D6200E809B4 /* Log.swift */,
C0C8E2B92AB02B6C00E809B4 /* Views */,
C041F2D82AB0243C0011752C /* Public */,
C041F2C52AB021E40011752C /* Assets.xcassets */,
C041F2C72AB021E40011752C /* Preview Content */,
);
path = smparkin;
sourceTree = "<group>";
};
C041F2C72AB021E40011752C /* Preview Content */ = {
isa = PBXGroup;
children = (
C041F2C82AB021E40011752C /* Preview Assets.xcassets */,
);
path = "Preview Content";
sourceTree = "<group>";
};
C0C8E2B92AB02B6C00E809B4 /* Views */ = {
isa = PBXGroup;
children = (
C0C8E2BA2AB02B6C00E809B4 /* 404.leaf */,
C0C8E2BB2AB02B6C00E809B4 /* home.leaf */,
C0C8E2BC2AB02B6C00E809B4 /* privacy.leaf */,
C0C8E2BD2AB02B6C00E809B4 /* welcome.leaf */,
);
path = Views;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
C041F2BD2AB021E30011752C /* smparkin */ = {
isa = PBXNativeTarget;
buildConfigurationList = C041F2CC2AB021E40011752C /* Build configuration list for PBXNativeTarget "smparkin" */;
buildPhases = (
C041F2BA2AB021E30011752C /* Sources */,
C041F2BB2AB021E30011752C /* Frameworks */,
C041F2BC2AB021E30011752C /* Resources */,
);
buildRules = (
);
dependencies = (
);
name = smparkin;
packageProductDependencies = (
C041F2D12AB0238F0011752C /* Vapor */,
C041F2D62AB023CA0011752C /* Leaf */,
);
productName = smparkin;
productReference = C041F2BE2AB021E30011752C /* smparkin.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
C041F2B62AB021E30011752C /* Project object */ = {
isa = PBXProject;
attributes = {
BuildIndependentTargetsInParallel = 1;
LastSwiftUpdateCheck = 1500;
LastUpgradeCheck = 1500;
TargetAttributes = {
C041F2BD2AB021E30011752C = {
CreatedOnToolsVersion = 15.0;
};
};
};
buildConfigurationList = C041F2B92AB021E30011752C /* Build configuration list for PBXProject "smparkin" */;
compatibilityVersion = "Xcode 14.0";
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = C041F2B52AB021E30011752C;
packageReferences = (
C041F2D02AB0238F0011752C /* XCRemoteSwiftPackageReference "vapor" */,
C041F2D52AB023CA0011752C /* XCRemoteSwiftPackageReference "leaf" */,
);
productRefGroup = C041F2BF2AB021E30011752C /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
C041F2BD2AB021E30011752C /* smparkin */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
C041F2BC2AB021E30011752C /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
C0C8E2BE2AB0304D00E809B4 /* home.leaf in Resources */,
C0C8E2C12AB0304D00E809B4 /* 404.leaf in Resources */,
C041F2C92AB021E40011752C /* Preview Assets.xcassets in Resources */,
C041F2DA2AB0243C0011752C /* Public in Resources */,
C041F2C62AB021E40011752C /* Assets.xcassets in Resources */,
C0C8E2C02AB0304D00E809B4 /* welcome.leaf in Resources */,
C0C8E2BF2AB0304D00E809B4 /* privacy.leaf in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
C041F2BA2AB021E30011752C /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
C041F2DF2AB0246C0011752C /* Server.swift in Sources */,
C041F2C42AB021E30011752C /* ContentView.swift in Sources */,
C0C8E2C52AB03D6200E809B4 /* Log.swift in Sources */,
C041F2C22AB021E30011752C /* smparkinApp.swift in Sources */,
C041F2DD2AB024510011752C /* Routes.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin XCBuildConfiguration section */
C041F2CA2AB021E40011752C /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
ENABLE_USER_SCRIPT_SANDBOXING = YES;
GCC_C_LANGUAGE_STANDARD = gnu17;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
"$(inherited)",
);
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 17.0;
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
};
name = Debug;
};
C041F2CB2AB021E40011752C /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_USER_SCRIPT_SANDBOXING = YES;
GCC_C_LANGUAGE_STANDARD = gnu17;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 17.0;
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
SDKROOT = iphoneos;
SWIFT_COMPILATION_MODE = wholemodule;
VALIDATE_PRODUCT = YES;
};
name = Release;
};
C041F2CD2AB021E40011752C /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_ASSET_PATHS = "\"smparkin/Preview Content\"";
DEVELOPMENT_TEAM = QR825BQSTL;
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES;
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
INFOPLIST_KEY_UILaunchScreen_Generation = YES;
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = in.smpark.smparkin;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_EMIT_LOC_STRINGS = YES;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
};
C041F2CE2AB021E40011752C /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_ASSET_PATHS = "\"smparkin/Preview Content\"";
DEVELOPMENT_TEAM = QR825BQSTL;
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES;
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
INFOPLIST_KEY_UILaunchScreen_Generation = YES;
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = in.smpark.smparkin;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_EMIT_LOC_STRINGS = YES;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
C041F2B92AB021E30011752C /* Build configuration list for PBXProject "smparkin" */ = {
isa = XCConfigurationList;
buildConfigurations = (
C041F2CA2AB021E40011752C /* Debug */,
C041F2CB2AB021E40011752C /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
C041F2CC2AB021E40011752C /* Build configuration list for PBXNativeTarget "smparkin" */ = {
isa = XCConfigurationList;
buildConfigurations = (
C041F2CD2AB021E40011752C /* Debug */,
C041F2CE2AB021E40011752C /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
/* Begin XCRemoteSwiftPackageReference section */
C041F2D02AB0238F0011752C /* XCRemoteSwiftPackageReference "vapor" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/vapor/vapor.git";
requirement = {
kind = upToNextMajorVersion;
minimumVersion = 4.81.0;
};
};
C041F2D52AB023CA0011752C /* XCRemoteSwiftPackageReference "leaf" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/vapor/leaf.git";
requirement = {
kind = upToNextMajorVersion;
minimumVersion = 4.2.4;
};
};
/* End XCRemoteSwiftPackageReference section */
/* Begin XCSwiftPackageProductDependency section */
C041F2D12AB0238F0011752C /* Vapor */ = {
isa = XCSwiftPackageProductDependency;
package = C041F2D02AB0238F0011752C /* XCRemoteSwiftPackageReference "vapor" */;
productName = Vapor;
};
C041F2D62AB023CA0011752C /* Leaf */ = {
isa = XCSwiftPackageProductDependency;
package = C041F2D52AB023CA0011752C /* XCRemoteSwiftPackageReference "leaf" */;
productName = Leaf;
};
/* End XCSwiftPackageProductDependency section */
};
rootObject = C041F2B62AB021E30011752C /* Project object */;
}

View File

@@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>

View File

@@ -1,194 +0,0 @@
{
"pins" : [
{
"identity" : "async-http-client",
"kind" : "remoteSourceControl",
"location" : "https://github.com/swift-server/async-http-client.git",
"state" : {
"revision" : "16f7e62c08c6969899ce6cc277041e868364e5cf",
"version" : "1.19.0"
}
},
{
"identity" : "async-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/async-kit.git",
"state" : {
"revision" : "eab9edff78e8ace20bd7cb6e792ab46d54f59ab9",
"version" : "1.18.0"
}
},
{
"identity" : "console-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/console-kit.git",
"state" : {
"revision" : "9a12000f4064a2bdc49068d7258292ec1bdc88fc",
"version" : "4.7.0"
}
},
{
"identity" : "leaf",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/leaf.git",
"state" : {
"revision" : "6fe0e843c6599f5189e45c7b08739ebc5c410c3b",
"version" : "4.2.4"
}
},
{
"identity" : "leaf-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/leaf-kit.git",
"state" : {
"revision" : "13f2fc4c8479113cd23876d9a434ef4573e368bb",
"version" : "1.10.2"
}
},
{
"identity" : "multipart-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/multipart-kit.git",
"state" : {
"revision" : "1adfd69df2da08f7931d4281b257475e32c96734",
"version" : "4.5.4"
}
},
{
"identity" : "routing-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/routing-kit.git",
"state" : {
"revision" : "e0539da5b60a60d7381f44cdcf04036f456cee2f",
"version" : "4.8.0"
}
},
{
"identity" : "swift-algorithms",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-algorithms.git",
"state" : {
"revision" : "b14b7f4c528c942f121c8b860b9410b2bf57825e",
"version" : "1.0.0"
}
},
{
"identity" : "swift-atomics",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-atomics.git",
"state" : {
"revision" : "6c89474e62719ddcc1e9614989fff2f68208fe10",
"version" : "1.1.0"
}
},
{
"identity" : "swift-collections",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-collections.git",
"state" : {
"revision" : "937e904258d22af6e447a0b72c0bc67583ef64a2",
"version" : "1.0.4"
}
},
{
"identity" : "swift-crypto",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-crypto.git",
"state" : {
"revision" : "60f13f60c4d093691934dc6cfdf5f508ada1f894",
"version" : "2.6.0"
}
},
{
"identity" : "swift-log",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-log.git",
"state" : {
"revision" : "532d8b529501fb73a2455b179e0bbb6d49b652ed",
"version" : "1.5.3"
}
},
{
"identity" : "swift-metrics",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-metrics.git",
"state" : {
"revision" : "971ba26378ab69c43737ee7ba967a896cb74c0d1",
"version" : "2.4.1"
}
},
{
"identity" : "swift-nio",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio.git",
"state" : {
"revision" : "cf281631ff10ec6111f2761052aa81896a83a007",
"version" : "2.58.0"
}
},
{
"identity" : "swift-nio-extras",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-extras.git",
"state" : {
"revision" : "0e0d0aab665ff1a0659ce75ac003081f2b1c8997",
"version" : "1.19.0"
}
},
{
"identity" : "swift-nio-http2",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-http2.git",
"state" : {
"revision" : "a8ccf13fa62775277a5d56844878c828bbb3be1a",
"version" : "1.27.0"
}
},
{
"identity" : "swift-nio-ssl",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-ssl.git",
"state" : {
"revision" : "320bd978cceb8e88c125dcbb774943a92f6286e9",
"version" : "2.25.0"
}
},
{
"identity" : "swift-nio-transport-services",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-transport-services.git",
"state" : {
"revision" : "e7403c35ca6bb539a7ca353b91cc2d8ec0362d58",
"version" : "1.19.0"
}
},
{
"identity" : "swift-numerics",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-numerics",
"state" : {
"revision" : "0a5bc04095a675662cf24757cc0640aa2204253b",
"version" : "1.0.2"
}
},
{
"identity" : "vapor",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/vapor.git",
"state" : {
"revision" : "03a08f6e88d5ca8c1cfd84f8367b21dfe050d082",
"version" : "4.81.0"
}
},
{
"identity" : "websocket-kit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vapor/websocket-kit.git",
"state" : {
"revision" : "53fe0639a98903858d0196b699720decb42aee7b",
"version" : "2.14.0"
}
}
],
"version" : 2
}

View File

@@ -1,11 +0,0 @@
{
"colors" : [
{
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

View File

@@ -1,13 +0,0 @@
{
"images" : [
{
"idiom" : "universal",
"platform" : "ios",
"size" : "1024x1024"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

View File

@@ -1,6 +0,0 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}

View File

@@ -1,29 +0,0 @@
//
// ContentView.swift
// smparkin
//
// Created by Stephen Parkinson on 9/11/23.
//
import SwiftUI
struct ContentView: View {
@StateObject var server: Server = Server(port: 8080)
var body: some View {
VStack {
Text(ProcessInfo().hostName + ":\(server.port)")
List(server.logs.reversed(), id: \.self) { log in
Text(log)
}
}
.padding()
.onAppear {
server.start()
}
}
}
#Preview {
ContentView()
}

View File

@@ -1,23 +0,0 @@
//
// Log.swift
// smparkin
//
// Created by Stephen Parkinson on 9/11/23.
//
import Vapor
struct LogMiddleware: Middleware {
let server: Server
init(server: Server) {
self.server = server
}
func respond(to request: Request, chainingTo next: Responder) -> EventLoopFuture<Response> {
DispatchQueue.main.async {
server.logs.append("\(server.dateFormatter.string(from: Date.now)) \(request.url.path)")
}
return next.respond(to: request)
}
}

View File

@@ -1,6 +0,0 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}

View File

@@ -1,58 +0,0 @@
import Leaf
import Vapor
import SwiftUI
class Server: ObservableObject {
@Published var logs: [String] = [String]()
let dateFormatter = ISO8601DateFormatter()
var app: Application
let port: Int
init(port: Int) {
self.port = port
app = Application(.production)
configure(app)
}
// Called before your application initializes.
private func configure(_ app: Application) {
app.http.server.configuration.hostname = "0.0.0.0"
app.http.server.configuration.port = port
//leaf
app.views.use(.leaf)
app.leaf.cache.isEnabled = app.environment.isRelease
app.leaf.configuration.rootDirectory = Bundle.main.bundlePath
//Register middleware
app.middleware.use(FileMiddleware(publicDirectory: "\(Bundle.main.bundlePath)/\(app.directory.publicDirectory)"))
app.middleware.use(ErrorMiddleware.default(environment: app.environment))
app.middleware.use(LogMiddleware.init(server: self))
//routes
do {
try routes(app)
} catch {
fatalError(error.localizedDescription)
}
}
func start() {
Task(priority: .background) {
do {
try app.start()
} catch {
fatalError(error.localizedDescription)
}
}
}
func stop() {
app.shutdown()
}
func restart() {
stop()
start()
}
}

View File

@@ -1,96 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<title>Stephen Parkinson</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Raleway">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<style>
body,h1,h2,h3,h4,h5,h6 {font-family: "Raleway", sans-serif}
</style>
</head>
<body class="w3-light-grey w3-content" style="max-width:1600px">
<!-- Sidebar/menu -->
<nav class="w3-sidebar w3-collapse w3-white w3-animate-left" style="z-index:3;width:300px;" id="mySidebar"><br>
<div class="w3-container">
<a href="#" onclick="w3_close()" class="w3-hide-large w3-right w3-jumbo w3-padding w3-hover-grey" title="close menu">
<i class="fa fa-remove"></i>
</a>
<img src="/images/me.jpg" style="width:45%;" class="w3-round"><br><br>
<h4><b>Stephen Parkinson</b></h4>
<p class="w3-text-grey">Software Engineer</p>
</div>
<div class="w3-bar-block">
<a href="#about" onclick="w3_close()" class="w3-bar-item w3-button w3-padding"><i class="fa fa-user fa-fw w3-margin-right"></i>ABOUT</a>
</div>
<div class="w3-panel w3-large">
<a href="https://www.linkedin.com/in/stephen-parkinson/">
<i class="fa fa-linkedin w3-hover-opacity"></i>
</a>
</div>
</nav>
<!-- Overlay effect when opening sidebar on small screens -->
<div class="w3-overlay w3-hide-large w3-animate-opacity" onclick="w3_close()" style="cursor:pointer" title="close side menu" id="myOverlay"></div>
<!-- !PAGE CONTENT! -->
<div class="w3-main" style="margin-left:300px">
<!-- Header -->
<header id="portfolio">
<a href="#"><img src="/images/me.jpg" style="width:65px;" class="w3-circle w3-right w3-margin w3-hide-large w3-hover-opacity"></a>
<span class="w3-button w3-hide-large w3-xxlarge w3-hover-text-grey" onclick="w3_open()"><i class="fa fa-bars"></i></span>
<div class="w3-container">
<h1><b></b></h1>
</div>
</header>
<!-- About -->
<div class="w3-row-padding w3-padding-16" id="about">
<div class="w3-col m6">
<img src="/images/trees.jpg" alt="A picture I took" style="width:100%">
</div>
</div>
<div class="w3-container w3-padding-large" style="margin-bottom:32px">
<h4><b>About Me</b></h4>
<p>I'm doing a lot of stuff with computers right now.</p>
<hr>
</div>
<!-- Contact Section -->
<div class="w3-container w3-padding-large w3-grey">
<h4 id="contact"><b>Contact Me</b></h4>
<div class="w3-row-padding w3-center w3-padding-24" style="margin:0 -16px">
<div class="w3-third w3-dark-grey">
<a href="mailto:stephen@smpark.in">
<p><i class="fa fa-envelope w3-xxlarge w3-text-light-grey"></i></p>
<p>stephen@smpark.in</p>
</a>
</div>
</div>
</div>
<div class="w3-black w3-center w3-padding-24">Powered by <a href="https://www.w3schools.com/w3css/default.asp" title="W3.CSS" target="_blank" class="w3-hover-opacity">w3.css</a></div>
<!-- End page content -->
</div>
<script>
// Script to open and close sidebar
function w3_open() {
document.getElementById("mySidebar").style.display = "block";
document.getElementById("myOverlay").style.display = "block";
}
function w3_close() {
document.getElementById("mySidebar").style.display = "none";
document.getElementById("myOverlay").style.display = "none";
}
</script>
</body>
</html>

View File

@@ -1,17 +0,0 @@
//
// smparkinApp.swift
// smparkin
//
// Created by Stephen Parkinson on 9/11/23.
//
import SwiftUI
@main
struct smparkinApp: App {
var body: some Scene {
WindowGroup {
ContentView()
}
}
}