4 Commits

Author SHA1 Message Date
1e72dbcfc2 feat: Bumps version
All checks were successful
CI / Run Tests (push) Successful in 2m36s
Release / release (push) Successful in 7s
2024-12-18 11:42:36 -05:00
a5b9280a46 feat: Adds release workflow to gitea
Some checks failed
CI / Run Tests (push) Has been cancelled
2024-12-18 11:41:39 -05:00
4b9c45dd5f fix: Fixes docker tests now that we're using curl to download configuration template file.
All checks were successful
CI / Run Tests (push) Successful in 3m2s
2024-12-18 10:54:09 -05:00
529aa80c47 feat: Updates to test homebrew
Some checks failed
CI / Run Tests (push) Failing after 2m34s
2024-12-18 10:18:28 -05:00
8 changed files with 43 additions and 11 deletions

View File

@@ -0,0 +1,19 @@
---
name: Release
on:
push:
tags:
- "*.*.*"
- "v*.*.*"
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Release
uses: softprops/action-gh-release@v2
with:
draft: true

1
.gitignore vendored
View File

@@ -11,3 +11,4 @@ DerivedData/
./hpa.toml ./hpa.toml
./Version.* ./Version.*
/*.json /*.json
hpa

View File

@@ -1,5 +1,5 @@
{ {
"originHash" : "bc31b11e5e7d488e0a9c1bf91cb572d29f782bfd8e43f44157036f8f3d282893", "originHash" : "f1d1e27e3b3b21d41b872325e0174196a323dc438bf3c9d9f99858856b457c96",
"pins" : [ "pins" : [
{ {
"identity" : "combine-schedulers", "identity" : "combine-schedulers",
@@ -33,8 +33,8 @@
"kind" : "remoteSourceControl", "kind" : "remoteSourceControl",
"location" : "https://git.housh.dev/michael/swift-cli-doc.git", "location" : "https://git.housh.dev/michael/swift-cli-doc.git",
"state" : { "state" : {
"revision" : "e524056dc65c5ce7a6a77bdea4e5fa0bf724019b", "revision" : "bbace73d974fd3e6985461431692bea773c7c5d8",
"version" : "0.2.0" "version" : "0.2.1"
} }
}, },
{ {

View File

@@ -20,7 +20,7 @@ let package = Package(
.package(url: "https://github.com/pointfreeco/swift-custom-dump.git", from: "1.3.3"), .package(url: "https://github.com/pointfreeco/swift-custom-dump.git", from: "1.3.3"),
.package(url: "https://github.com/pointfreeco/swift-dependencies", from: "1.5.2"), .package(url: "https://github.com/pointfreeco/swift-dependencies", from: "1.5.2"),
.package(url: "https://github.com/m-housh/swift-shell-client.git", from: "0.1.0"), .package(url: "https://github.com/m-housh/swift-shell-client.git", from: "0.1.0"),
.package(url: "https://git.housh.dev/michael/swift-cli-doc.git", from: "0.2.0"), .package(url: "https://git.housh.dev/michael/swift-cli-doc.git", from: "0.2.1"),
.package(url: "https://github.com/m-housh/swift-cli-version.git", from: "0.1.0"), .package(url: "https://github.com/m-housh/swift-cli-version.git", from: "0.1.0"),
.package(url: "https://github.com/LebJe/TOMLKit.git", from: "0.5.0") .package(url: "https://github.com/LebJe/TOMLKit.git", from: "0.5.0")
], ],

View File

@@ -1,2 +1,2 @@
// Do not set this variable, it is set during the build process. // Do not set this variable, it is set during the build process.
let VERSION: String? = "0.1.1" let VERSION: String? = "0.1.5"

View File

@@ -15,6 +15,7 @@ FROM swift:${SWIFT_IMAGE_VERSION}-slim
RUN export DEBIAN_FRONTEND=nointeractive DEBCONF_NOINTERACTIVE_SEEN=true && apt-get -q update && \ RUN export DEBIAN_FRONTEND=nointeractive DEBCONF_NOINTERACTIVE_SEEN=true && apt-get -q update && \
apt-get -q install -y \ apt-get -q install -y \
ansible \ ansible \
curl \
pandoc \ pandoc \
texlive \ texlive \
&& rm -r /var/lib/apt/lists/* && rm -r /var/lib/apt/lists/*

View File

@@ -2,6 +2,11 @@
ARG SWIFT_IMAGE_VERSION="6.0.3" ARG SWIFT_IMAGE_VERSION="6.0.3"
FROM swift:${SWIFT_IMAGE_VERSION} FROM swift:${SWIFT_IMAGE_VERSION}
RUN export DEBIAN_FRONTEND=nointeractive DEBCONF_NOINTERACTIVE_SEEN=true && apt-get -q update && \
apt-get -q install -y \
curl \
&& rm -r /var/lib/apt/lists/*
WORKDIR /app WORKDIR /app
COPY ./Package.* ./ COPY ./Package.* ./
RUN swift package resolve RUN swift package resolve

View File

@@ -10,13 +10,16 @@ formula := "hpa"
bottle: bottle:
@brew uninstall {{formula}} || true @brew uninstall {{formula}} || true
@brew tap {{tap}} {{tap_url}} @brew tap {{tap}} {{tap_url}}
@brew install --build-bottle {{formula}} @brew install --build-bottle {{tap}}/{{formula}}
@brew bottle {{formula}} --json @brew bottle {{formula}}
bottle="$(ls *.gz)" && mv "${bottle}" "${bottle/--/-}" bottle="$(ls *.gz)" && mv "${bottle}" "${bottle/--/-}"
# Build the command-line tool. # Build the command-line tool.
build mode="debug": build configuration="debug" arch="arm64":
swift build -c {{mode}} swift build \
--disable-sandbox \
--configuration {{configuration}} \
--arch {{arch}}
alias b := build alias b := build
@@ -26,11 +29,14 @@ build-docker file="Dockerfile" tag="latest":
--file docker/{{file}} \ --file docker/{{file}} \
--tag {{docker_image_name}}:{{tag}} . --tag {{docker_image_name}}:{{tag}} .
build-docker-test: (build-docker "Dockerfile.test" "test")
# Build the docker test image used for testing. # Build the docker test image used for testing.
build-docker-test: (build-docker "Dockerfile.test" "test") build-docker-test: (build-docker "Dockerfile.test" "test")
build-universal-binary: (build "release" "arm64") (build "release" "x86_64")
@lipo -create -output {{formula}} \
".build/arm64-apple-macosx/release/hpa" \
".build/x86_64-apple-macosx/release/hpa"
# Run tests. # Run tests.
test *ARGS: test *ARGS:
swift test {{ARGS}} swift test {{ARGS}}