Skip to content

Commit

Permalink
Merge pull request #2 from chrovis/feature/compile-opts
Browse files Browse the repository at this point in the history
Set compile options
  • Loading branch information
alumi authored May 1, 2024
2 parents 16427e0 + 83a9b3f commit 2166263
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 6 deletions.
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,15 @@ hgvs

`gnife [type] [command] --help` to display detailed usage of each command.

## JVM Options

To pass extra arguments to the JVM, set the `GNIFE_JVM_OPTS` environment
variable.

```sh
export GNIFE_JVM_OPTS="-XX:TieredStopAtLevel=1 -Xmx4g"
```

## Test

To run tests,
Expand Down
12 changes: 8 additions & 4 deletions build.clj
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@

(def version (format "0.1.%s" (b/git-count-revs nil)))
(def class-dir "target/classes")
(def basis (b/create-basis {:project "deps.edn"}))
(def uber-file "target/gnife.jar")
(def bin-file "target/gnife")

;; delay to defer side effects (artifact downloads)
(def basis (delay (b/create-basis {:project "deps.edn"})))

(defn clean [_]
(b/delete {:path "target"}))

Expand All @@ -19,12 +21,14 @@
:target-dir class-dir})
(b/write-file {:path (str class-dir "/VERSION")
:string version})
(b/compile-clj {:basis basis
(b/compile-clj {:basis @basis
:src-dirs ["src"]
:class-dir class-dir})
:class-dir class-dir
:compile-opts {:elide-meta [:doc :file :line :added]
:direct-linking true}})
(b/uber {:class-dir class-dir
:uber-file uber-file
:basis basis
:basis @basis
:main 'gnife.main}))

(def ^String preamble
Expand Down
4 changes: 2 additions & 2 deletions deps.edn
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{:deps {clj-hgvs/clj-hgvs {:mvn/version "0.4.7"}
clj-sub-command/clj-sub-command {:mvn/version "0.6.0"}
cljam/cljam {:mvn/version "0.8.4"}
org.clojure/clojure {:mvn/version "1.11.1"}
org.clojure/clojure {:mvn/version "1.11.3"}
org.clojure/tools.cli {:mvn/version "1.1.230"}
varity/varity {:mvn/version "0.11.0"}}

Expand All @@ -22,5 +22,5 @@

:build
{:extra-deps {io.github.clojure/tools.build
{:git/tag "v0.9.6" :git/sha "8e78bcc"}}
{:git/tag "v0.10.0" :git/sha "3a2c484"}}
:ns-default build}}}

0 comments on commit 2166263

Please sign in to comment.