Skip to content

Commit 1b9b216

Browse files
ci: add initial workflow to build and upload the application uber jar
1 parent 6a0f366 commit 1b9b216

2 files changed

Lines changed: 61 additions & 1 deletion

File tree

.github/workflows/ci.yaml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: Linux
2+
3+
on:
4+
push:
5+
branches: ["main"]
6+
paths:
7+
# files to watch
8+
- "deps.edn"
9+
- "build.clj"
10+
# directories to watch
11+
- "source/**"
12+
13+
pull_request:
14+
branches: ["main"]
15+
paths:
16+
# files to watch
17+
- "deps.edn"
18+
- "build.clj"
19+
# directories to watch
20+
- "source/**"
21+
22+
jobs:
23+
build:
24+
runs-on: ubuntu-latest
25+
26+
steps:
27+
- name: Setup Repository
28+
uses: actions/checkout@v6
29+
30+
- name: Setup Java
31+
uses: actions/setup-java@v5
32+
with:
33+
distribution: "oracle"
34+
java-version: "21"
35+
36+
- name: Setup Clojure
37+
uses: DeLaGuardo/setup-clojure@13.4
38+
with:
39+
cli: 1.12.3
40+
41+
- name: Setup Cache
42+
uses: actions/cache@v5
43+
with:
44+
key: clojure-dependencies-${{ hashFiles('deps.edn') }}
45+
path: |
46+
.cpcache
47+
~/.gitlibs
48+
~/.deps.clj
49+
~/.m2/repository
50+
restore-keys: clojure-dependencies-
51+
52+
- name: Compile & Package Project
53+
run: clj -T:build package
54+
55+
- name: Upload Artifact
56+
uses: actions/upload-artifact@v5
57+
with:
58+
path: target/application-*.jar
59+
name: Application Uber Jar
60+
if-no-files-found: error

source/entrypoint.clj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
(:gen-class)
33
(:require [clojure.java.io :as io]))
44

5-
(def version "0.1.0")
5+
(def version "0.0.0")
66

77
(def resource-path "config.json")
88
(def resource-content (->

0 commit comments

Comments
 (0)