A study of an interpreter of measurement program definitions written in clojure.
sudo apt install leiningen
zypper ar https://download.opensuse.org/repositories/devel:/languages:/clojure/openSUSE_Leap_15.1/devel:languages:clojure.repo
zypper ref devel_languages_clojure
zypper in leiningen
git clone https://github.com/wactbprot/cmp.git
cd cmp
lein deps
lein repl
Softlink or copy your special configuration (here ce3-conf.edn) to config.edn.
ln -s /<path-to-devproxy>/devproxy/resources/ce3-conf.edn /<path-to-devproxy>/devproxy/resources/config.edn
cp /<path-to-devproxy>/devproxy/resources/ce3-conf.edn /<path-to-devproxy>/devproxy/resources/config.edn
User interaction with cmp is REPL only. The core
namespace is the entry point. Use (dir cmp.core) or
take a look at the api to get an overview.
Since 0.20.0 the pp-table concept is dropped. The data browser portal seems to be the way to go.
ToDo: write a new example session on how to proceed.
(def portal (p/open))
(add-tap #'p/submit)
(tap> (c-data))
All of the mp state is kept in a redis database.
Since version 0.3.0 cmp relies on
Keyspace Notifications.
Therefore it is necassary to replace in /etc/redis/redis.conf:
notify-keyspace-events ""
by
notify-keyspace-events AK
and restart the service:
# restart
$ sudo systemctl restart redis.service
# check status
$ sudo systemctl status redis.service
sudo snap install redis-desktop-manager$ npm install -g redis-commander
## --> http://localhost:8081/
All devel commands have to be executed in the root directory of cmp.
$ cd path/to/cmp
$ lein marg resources/example-session.clj
(re)generate documentation
$ lein codox
$ lein test
Example utils-tests:
(ns cmp.utils-test)
(use 'clojure.test)
(run-tests)
$ lein cloverage