Liking cljdoc? Tell your friends :D

cli-matic.utils-convert-config

Convert old configuration (v1) to the new format (v2), in a printable way.

This comes in handy when evolving existing scripts.

ATM it only works for Clojure, and not so well, as symbol de-munging is not 100% deterministic (minuses and underscores are mixed).

This namespace is not referenced from anywhere else in CLI-matic.

#  Convert old configuration (v1) to the new format (v2), in a printable way.

This comes in handy when evolving existing scripts.

ATM it only works for Clojure, and not so well, as symbol
de-munging is not 100% deterministic (minuses and underscores are mixed).

This namespace is not referenced from anywhere else in CLI-matic.

raw docstring

convert-and-printclj

(convert-and-print cfg-v1)

Given a configuration v1, pretty-prints the corresponding configuration v2 that you can copy-and-paste it into your scripts.

Given a configuration v1, pretty-prints the corresponding
configuration v2 that you can copy-and-paste it into
your scripts.
sourceraw docstring

fn->classNameclj

(fn->className a-fn)

Extracts the class name for a given function.

Extracts the class name for a given function.
sourceraw docstring

fn-namecljmacro

(fn-name f)

This works, but only as a macro.

This works, but only as a macro.
sourceraw docstring

replace-runs-entriesclj

(replace-runs-entries v)

Whenever we find an entry [:runs fnxxxx] we replace the function with its symbol.

Whenever we find an entry [:runs fnxxxx] we  replace the
function with its symbol.
sourceraw docstring

unmangle-fnclj

(unmangle-fn a-fn)

Given a non-anonymous function, returns its Clojure name as a symbol.

Given a non-anonymous function, returns its Clojure name as a symbol.
sourceraw docstring

unmangle-fn-nameclj

(unmangle-fn-name a-fn-name)

Given the name of a class that implements a Clojure function, returns the function's name in Clojure. Note: If the true Clojure function name contains any underscores (a rare occurrence), the unmangled name will contain hyphens at those locations instead.

Inspired by https://www.mail-archive.com/clojure@googlegroups.com/msg13018.html

There is a similar function in 'clojure.repl/demunge' that screws up in a very similar way for symbols that have a '_' or a '-' in their name,

Given the name of a class that implements a Clojure function, returns the function's name in Clojure. Note: If the true Clojure function name
 contains any underscores (a rare occurrence), the unmangled name will
 contain hyphens at those locations instead.

Inspired by https://www.mail-archive.com/clojure@googlegroups.com/msg13018.html

There is a similar function in 'clojure.repl/demunge' that screws up
in a very similar way for symbols  that have a '_' or a '-' in their name,

 
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close