Fork me on GitHub

I was experimenting with nubank/matcher-combinators earlier today and noticed that the cider test results show raw escape characters instead of applying a color to the text. Am I doing something wrong or is this related to


Hi - are the ClojureDocs lookups using C-c C-d C-c (`cider-clojuredocs`)something that requires an internet connection?


I think it requires an internet connection once to get the entire corpus and then individual lookups use the local versions

👍 1

You only need an internet connection to update the local data. We ship some export (basically an EDN file) with Orchard and we update it there from time to time. Older versions of CIDER downloaded the data locally the first time you needed it.

cider 1

Is there a way to change the order of arguments in a function definitionusing CIDER or the clj-refactor extension that will update usage sites?


If that isn't directly supported, I am wondering what the best way to do something like that might be.


no it's not offered. clj-refactor and clojure-lsp offer "find usages" functionality. So you can jump to each callsite and edit it by hand (I'd use some paredit to move the symbols around)


If you are interested in a generalized/automated feature, I reckon that would take some rewrite-clj skills


In my experience you shouldn't have to do that a lot. Don't get me wrong, having great tooling is awesome but in this case what you're asking for is a tool to contain complexity created by bad design. Some pointers: 1. In general prefer maps over positional arguments 2. Try not to break your APIs, even if they're internal. Instead of having a messy git diff and risk breaking something during the refactoring, keep the old code as is for compatibility reasons (mark it as deprecated), and create a function that wraps it, using a map. Then gradually convert your usages to the new API. No need to make all the changes in your code in one go. 3. If for some reason you don't want to do either of the above or if few changes are involved, consider refactoring the code by hand (search for usages and change them yourself) - not always possible but sometimes I like to do it as an exercise of why good design is important It helps to ask yourself why. What's wrong with the existing code? Why do I need to refactor it? I've found that most of the time it isn't worth the trouble.

👍 2