-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3134d48
commit 60df404
Showing
5 changed files
with
98 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
name: Release | ||
on: [push] | ||
|
||
jobs: | ||
publish: | ||
runs-on: ubuntu-latest | ||
env: | ||
VERSION: ${{ github.ref_name }} | ||
steps: | ||
- name: Checkout git repo | ||
uses: actions/checkout@v2 | ||
|
||
- uses: actions/setup-java@v2 | ||
with: | ||
distribution: 'temurin' | ||
java-version: '21' | ||
|
||
- uses: extractions/setup-just@v1 | ||
|
||
- uses: DeLaGuardo/[email protected] | ||
with: | ||
cli: latest | ||
|
||
- name: Build | ||
run: | | ||
just build | ||
- name: Release | ||
if: ${{ github.ref_type == 'tag' && startsWith(github.ref_name, 'v') }} | ||
env: | ||
CLOJARS_USERNAME: infrastructure-kepler16-com | ||
CLOJARS_PASSWORD: ${{ secrets.CLOJARS_PASSWORD }} | ||
run: | | ||
just release |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,5 @@ | ||
test *ARGS: | ||
clojure -T:kmono run :exec "\"just test\"" {{ ARGS }} | ||
build: | ||
clojure -T:build jar | ||
|
||
build *ARGS: | ||
clojure -T:kmono run :exec :build {{ ARGS }} | ||
|
||
release *ARGS: | ||
clojure -T:kmono run :exec :release {{ ARGS }} | ||
release: | ||
clojure -T:build release |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,3 @@ | ||
# Forge | ||
|
||
A clojure test runner | ||
|
||
+ Parallel execution | ||
+ Human parseable output | ||
A parallel test runner for clojure.test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
(ns build | ||
(:require | ||
[clojure.string :as str] | ||
[clojure.tools.build.api :as b] | ||
[deps-deploy.deps-deploy :as deps-deploy])) | ||
|
||
(def basis | ||
(b/create-basis {})) | ||
|
||
(def lib 'com.kepler16/forge) | ||
(def version | ||
(str/replace (or (System/getenv "VERSION") | ||
"0.0.0") | ||
#"v" "")) | ||
(def class-dir "target/classes") | ||
(def jar-file "target/lib.jar") | ||
|
||
(defn clean [_] | ||
(b/delete {:path "target"})) | ||
|
||
(defn jar [_] | ||
(clean nil) | ||
|
||
(b/write-pom {:class-dir class-dir | ||
:lib lib | ||
:version version | ||
:basis basis | ||
:src-dirs ["src"] | ||
:pom-data [[:description "Parallel test runner for clojure.test"] | ||
[:url "https://github.com/kepler16/forge"] | ||
[:licenses | ||
[:license | ||
[:name "MIT"] | ||
[:url "https://opensource.org/license/mit"]]]]}) | ||
|
||
(b/copy-dir {:src-dirs ["src"] | ||
:target-dir class-dir}) | ||
|
||
(b/compile-clj {:basis basis | ||
:src-dirs [class-dir] | ||
:class-dir class-dir | ||
:ns-compile ['k16.forge] | ||
:java-opts ["-Dclojure.compiler.direct-linking=true" | ||
"-Dclojure.spec.skip-macros=true"]}) | ||
|
||
(b/jar {:class-dir class-dir | ||
:jar-file jar-file})) | ||
|
||
(defn release [_] | ||
(deps-deploy/deploy {:installer :remote | ||
:artifact (b/resolve-path jar-file) | ||
:pom-file (b/pom-path {:lib lib | ||
:class-dir class-dir})})) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,10 @@ | ||
{:deps {org.clj-commons/pretty {:mvn/version "3.0.0"} | ||
{:paths ["src"] | ||
|
||
:deps {org.clj-commons/pretty {:mvn/version "3.0.0"} | ||
mvxcvi/puget {:mvn/version "1.3.4"} | ||
cli-matic/cli-matic {:mvn/version "0.5.4"} | ||
lambdaisland/deep-diff2 {:mvn/version "2.11.216"}} | ||
|
||
:aliases {:kmono {:deps {com.kepler16/kmono {:mvn/version "2.0.1.0"}} | ||
:ns-default k16.kmono.api}}} | ||
:aliases {:build {:deps {io.github.clojure/tools.build {:mvn/version "0.9.6"} | ||
slipset/deps-deploy {:mvn/version "0.2.2"}} | ||
:ns-default build}}} |