Skip to content

Commit

Permalink
Update package (#1)
Browse files Browse the repository at this point in the history
- Add CI, license, and NOTICES
- Update CMustache to the 1.2.6 version of mustach
- Bump Swift requirement to 5.7 and add platform version minimums
- Fix build on Arch Linux
- Remove outdated test files
- Update mustach API usage

The `MustacheTests.testSectionArray` test currently fails. This appears
to have been the case for a long time, and also doesn't appear to affect
the Vapor toolbox's usage.

Arch Linux build was tested manually; build completes cleanly with no
errors or warnings.
  • Loading branch information
gwynne authored Mar 2, 2024
1 parent d98546e commit 052c094
Show file tree
Hide file tree
Showing 13 changed files with 679 additions and 473 deletions.
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @gwynne
11 changes: 11 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: test
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
on:
pull_request: { types: [opened, reopened, synchronize, ready_for_review] }
push: { branches: [ main ] }

jobs:
unit-tests:
uses: vapor/ci/.github/workflows/run-unit-tests.yml@main
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2024 Vapor

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
6 changes: 6 additions & 0 deletions NOTICES.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
This product contains the mustach.h and mustach.c files from the mustach parser distribution.

* LICENSE (ISC):
* https://gitlab.com/jobol/mustach/-/blob/b55963fd0ff2d671f8c3546c26da4238152b0f99/LICENSE.txt
* HOMEPAGE:
* http://mustache.github.io/
23 changes: 18 additions & 5 deletions Package.swift
Original file line number Diff line number Diff line change
@@ -1,18 +1,31 @@
// swift-tools-version:5.1
// swift-tools-version:5.7
import PackageDescription

let package = Package(
name: "mustache",
platforms: [
.macOS(.v10_14)
.macOS(.v10_15),
.iOS(.v13),
.watchOS(.v6),
.tvOS(.v13),
],
products: [
.library(name: "Mustache", targets: ["Mustache"]),
],
dependencies: [ ],
dependencies: [],
targets: [
.target(name: "CMustache"),
.target(name: "Mustache", dependencies: ["CMustache"]),
.testTarget(name: "MustacheTests", dependencies: ["Mustache"]),
.target(
name: "Mustache",
dependencies: [
.target(name: "CMustache"),
]
),
.testTarget(
name: "MustacheTests",
dependencies: [
.target(name: "Mustache"),
]
),
]
)
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# Mustache

Swift wrapper around C mustache parser.
A Swift wrapper around the [mustach parser](http://mustache.github.io/).
Loading

0 comments on commit 052c094

Please sign in to comment.