Fork me on GitHub

Is there a way to configure the temp directory location used by build-clj/ during uberjar compilation?


The system property should do it


perfect - that worked, thank you


My instinct is to append a ! to any function that isn't homoiconic, e.g. even something that relies on an implicit time seed or something, but in some of the books I've read, I see that pattern really underused imo with tons of functions that aren't really pure, e.g. relying on global state or, more rarely, even altering global state. Any general recommendations?


Note - homoiconic does not mean pure. I've found Clojure's concept of purity to be different from Haskell's. In Haskell, slurp is impure, it reads from the environment. In Clojure, slurp is "just a mechanism". It's parameterized, and that parameter could be a URL. That URL could contain a content ID. So whether slurp's beavior is causing a side effect or not depends on the environment slurp is used in. In contrast, swap! is something you only do for side effects. I've gotten a lot out of Rich's The Language of The System. Purity can be considered a "just code" concept. Or you can use values when you design whole systems.


In Clojure I feel ! is used as a warning. Any function where you got to be a bit careful, that there might be some gotcha or context specific thing might have a ! at the end,


This often is the case for impure things


But some impure things sometimes are straightforward, so they won't always have ! at the end


It's all just a convention, and people do it differently. So the question is what value do you get out of it. If you've found it useful to have ! indicate pure/impure in a strict way, keep doing it. If it's just some added burden but it never really comes in handy, maybe stop.

thanks3 1

"doing this operation more than once in a row will have different, stacked results" is kinda how i read ! at the end of a function name currently


How does that intuition apply to reset!?


the exclamation point is also for writing to a database, or mutating a variable, in the case of (swap! atom inc) and (reset! atom val) @U3X7174KS brings up a fun point that reset! is a bit special the ! is indicative of "hey this is different than the usual 'all the same inputs yield all the same outputs every time' functional style"

👍 1

Hi I am using calva for clojure development , I was wondering if I could disable the IO writing to the output calva file because it is actually putting a heavy load on my system even when the file is closed inside vs code


Maybe try #calva