Skip to content

cleancoders/c3kit-scaffold

Repository files navigation

Scaffold

Scaffold

A library component of c3kit - Clean Coders Clojure Kit.

"Truth forever on the scaffold, Wrong forever on the throne,— Yet that scaffold sways the future" - James Russell Lowell

Scaffold Build

Use Scaffold to build your cljs and css (garden).

  • cljs.clj : task to compile clojurescript
  • css.clj : task to compile garden into css

Development

# Run the JVM tests
clj -M:test:spec
clj -M:test:spec -a         # auto runner

# Compile and Run JS tests
clj -M:test:cljs once
clj -M:test:cljs            # auto runner

ClojureScript transpiling/testing

Add the following alias to your deps.edn:

    :cljs  {:main-opts ["-m" "c3kit.scaffold.cljs"]}

config/cljs.edn must exist in the classpath. Example config file

Invoke compile with:

clj -M:test:cljs once               # transpile just once
clj -M:test:cljs                    # retranspile every time code changes
C3_ENV=production clj -M:test:cljs  # transpile production config

CSS transpiling

Write all your CSS code in Clojure using Garden.

Add the following alias to your deps.edn:

    :css  {:main-opts ["-m" "c3kit.scaffold.css"]}

config/css.edn must exist in the classpath. Example config file

Invoke transpile with:

clj -M:test:css once               # transpile just once
clj -M:test:css                    # retranspile every time code changes

Deployment

In order to deploy to c3kit you must be a member of the Clojars group com.cleancoders.c3kit.

  1. Go to https://clojars.org/tokens and configure a token with the appropriate scope
  2. Set the following environment variables
CLOJARS_USERNAME=<your username>
CLOJARS_PASSWORD=<your deploy key>
  1. Update VERSION file
  2. clj -T:build deploy

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 5