Skip to content

Commit

Permalink
added sample ci files
Browse files Browse the repository at this point in the history
  • Loading branch information
awkay committed Nov 28, 2020
1 parent e37227f commit 9aa9107
Show file tree
Hide file tree
Showing 2 changed files with 59 additions and 0 deletions.
36 changes: 36 additions & 0 deletions sample-ci-files/circleci-config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
version: 2
jobs:
cljs:
docker:
- image: circleci/clojure:openjdk-8-tools-deps-node-browsers
steps:
- checkout
- restore_cache:
key: cljs-{{ checksum "deps.edn" }}-{{ checksum "package.json" }}
- run: npm install
- run: npx shadow-cljs -A:dev -v compile ci-tests
- run: ls -l target
- run: npx karma start --single-run
- save_cache:
paths:
- node_modules
- ~/.m2
key: cljs-{{ checksum "deps.edn" }}-{{ checksum "package.json" }}
clj:
docker:
- image: circleci/clojure:tools-deps-1.9.0.394
steps:
- checkout
- restore_cache:
key: clj-{{ checksum "deps.edn" }}
- run: clojure -A:dev:test:clj-tests -J-Dguardrails.enabled=true -J-Dguardrails.config=guardrails-test.edn
- save_cache:
paths:
- ~/.m2
key: clj-{{ checksum "deps.edn" }}
workflows:
version: 2
fullstack:
jobs:
- clj
- cljs
23 changes: 23 additions & 0 deletions sample-ci-files/gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
cache:
key: one-key-to-rule-them-all
paths:
- node_modules/
- google-chrome-stable_current_amd64.deb

default:
image: clojure:openjdk-8-tools-deps
before_script:
- apt-get update

clj:
script:
- clojure -A:dev:clj-tests

cljs:
script:
- apt-get install -y nodejs npm wget
- ls google-chrome-stable_current_amd64.deb || wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
- apt install -y ./google-chrome-stable_current_amd64.deb
- npm install
- npx shadow-cljs compile ci-tests
- npx karma start --single-run

0 comments on commit 9aa9107

Please sign in to comment.