Skip to content

Commit b995df1

Browse files
SalvatoreTostiSalvatore Tosti
and
Salvatore Tosti
authored
add cljfmt (#41)
Co-authored-by: Salvatore Tosti <[email protected]>
1 parent afdf247 commit b995df1

File tree

5 files changed

+57
-0
lines changed

5 files changed

+57
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ Here the list of libraries tested:
2323
| :white_check_mark: | [aws-api+s3](./aws-api-s3) | Cognitect AWS client library | |
2424
| :white_check_mark: | [carmine](./carmine) | Redis client and message queue for Clojure | |
2525
| :white_check_mark: | [cheshire](./cheshire) | JSON parser/writer | |
26+
| :white_check_mark: | [cljfmt](./cljfmt) | Source Formatter | |
2627
| :white_check_mark: | [clj-http-lite](./clj-http-lite) | Web client | |
2728
| :x: | [clj-sophia](./clj-sophia) | A fast RAM-Disk hybrid storage | *Runtime error/JNA* |
2829
| :white_check_mark: | [clj-uuid](./clj-uuid) | RFC4122 Unique Identifiers for Clojure | No objects in namespaced uuids |

cljfmt/.gitignore

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
/target
2+
/classes
3+
/checkouts
4+
profiles.clj
5+
pom.xml
6+
pom.xml.asc
7+
*.jar
8+
*.class
9+
/.lein-*
10+
/.nrepl-port
11+
.hgignore
12+
.hg/

cljfmt/README.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# cljfmt
2+
3+
Use this project as template for testing a specific library with GraalVM **native-image**
4+
5+
## Usage
6+
7+
Currently testing:
8+
9+
[cljfmt "0.7.0"]
10+
11+
Test with:
12+
13+
lein do clean, uberjar, native, run-native
14+
15+
## Results
16+
`[cljfmt.main :as fmt]` :white_check_mark:.

cljfmt/project.clj

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
(defproject sample-project "0.1.0-SNAPSHOT"
2+
3+
:dependencies [[org.clojure/clojure "1.10.3"]
4+
[cljfmt "0.7.0"]]
5+
6+
:main simple.main
7+
8+
:uberjar-name "simple-main.jar"
9+
10+
:profiles {:uberjar {:aot :all}
11+
:dev {:plugins [[lein-shell "0.5.0"]]}}
12+
13+
:aliases
14+
{"native"
15+
["shell"
16+
"native-image" "--report-unsupported-elements-at-runtime" "--no-server" "--no-fallback"
17+
"--initialize-at-build-time"
18+
"-jar" "./target/${:uberjar-name:-${:name}-${:version}-standalone.jar}"
19+
"-H:Name=./target/${:name}"]
20+
21+
"run-native" ["shell" "./target/${:name}"]})

cljfmt/src/simple/main.clj

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
(ns simple.main
2+
(:require [cljfmt.main :as fmt])
3+
4+
(:gen-class))
5+
6+
(defn -main [& args]
7+
(apply fmt/-main args))

0 commit comments

Comments
 (0)