cljdoc

https://cljdoc.org/ & https://github.com/cljdoc/cljdoc
dharrigan 2020-12-20T15:32:28.180100Z

I'm obviously doing something wrong. I'm trying to "preview" documentation for a library. Following the instructions on the webpage, I've cloned the repo, and I'm executing this command within the project (library) directory...

dharrigan 2020-12-20T15:33:02.180300Z

../cljdoc/script/cljdoc ingest --project io.sentry/sentry-clj --version 1.1.136 --git $(pwd) --rev $(git rev-parse HEAD)

dharrigan 2020-12-20T15:33:18.180600Z

No matter what I try to do, I keep getting this error:

dharrigan 2020-12-20T15:33:27.180800Z

** ERROR: **
Exception: #error {
 :cause Requested version cannot be found in configured repositories: [io.sentry/sentry-clj 1.1.136]
 :data {:project io.sentry/sentry-clj, :version 1.1.136}
 :via
 [{:type clojure.lang.ExceptionInfo
   :message Requested version cannot be found in configured repositories: [io.sentry/sentry-clj 1.1.136]
   :data {:project io.sentry/sentry-clj, :version 1.1.136}
   :at [cljdoc.util.repositories$artifact_uris invokeStatic repositories.clj 119]}]
 :trace
 [[cljdoc.util.repositories$artifact_uris invokeStatic repositories.clj 119]

dharrigan 2020-12-20T15:37:54.181100Z

Right figured it out.

dharrigan 2020-12-20T15:38:40.181700Z

I have to deploy it to my local m2 first. I guess, there's no way for it to simply scan the local src directory and not rely upon deployments?

lread 2020-12-20T17:06:48.188600Z

Hiya @dharrigan! Glad you got sorted out. > I guess, there’s no way for it to simply scan the local src directory and not rely upon deployments? We could probably make this work, but right now we are simply reusing cljdoc production behaviours. Keeping the number of variables down has its advantages. But I do see your point, I was just doing a local preview yesterday, and it is on the heavy and slow side. I find a script helps, here’s https://github.com/lread/rewrite-cljc-playground/blob/master/script/cljdoc_preview.clj.

dharrigan 2020-12-20T18:33:51.188900Z

thank you lee, will try 🙂

seancorfield 2020-12-20T23:40:48.190Z

Just a quick sanity check: I know that ^:no-doc on an ns form will tell cljdoc to ignore it. Does that work on an individual def/`defn` basis as well or should I use something else to exclude a (public) function from the docs?

seancorfield 2020-12-21T18:09:24.190800Z

I should just RTFM 🙂

martinklepsch 2020-12-21T18:51:34.191Z

no worries 😄