clojure-europe

For people in Europe... or elsewhere... UGT https://indieweb.org/Universal_Greeting_Time
djm 2021-05-19T05:11:13.006Z

πŸ‘‹

RAMart 2021-05-19T05:14:31.006300Z

β˜• πŸ₯

pez 2021-05-19T05:49:30.007Z

Ah, something to go with the coffee would be sweet! Morning, btw. πŸ˜ƒ

2021-05-19T05:59:42.007100Z

Morning

dharrigan 2021-05-19T06:01:25.007300Z

Morning!

slipset 2021-05-19T07:52:26.007500Z

morning

slipset 2021-05-19T07:54:26.009300Z

So finished up removing our old java based logging and replacing it with timbre. In doing so I had to read a bit of the source for timbre, which is kind’a interesting. Fairly different from how I write code πŸ™‚ Not passing judgement, just observations.

borkdude 2021-05-19T07:56:01.009600Z

We've been using timbre for a long time and it serves us well.

thomas 2021-05-19T07:56:13.009800Z

mogge

raymcdermott 2021-05-19T07:57:49.010Z

morning

simongray 2021-05-19T09:59:45.010100Z

@slipset what's notable in particular?

ordnungswidrig 2021-05-19T10:05:06.010300Z

good morning!

slipset 2021-05-19T11:27:11.010700Z

@simongray Like this top-level let with defs inside https://github.com/ptaoussanis/timbre/blob/master/src/taoensso/timbre.cljc#L244

slipset 2021-05-19T11:27:51.011100Z

Indentation here https://github.com/ptaoussanis/timbre/blob/master/src/taoensso/timbre.cljc#L337 is somewhat unusual to me?

πŸ‘€ 1
borkdude 2021-05-19T11:33:08.011400Z

Recorded my talk...

πŸ‘ 3
1
🍻 1
borkdude 2021-05-19T11:58:29.012400Z

@slipset let over lambda is a useful pattern, if you want to share data between functions but not necessarily want to expose that data as top-level vars

borkdude 2021-05-19T11:59:41.012900Z

But it's less usual than just defining some private vars I guess

slipset 2021-05-19T12:01:59.013800Z

Unrelated, but map-vals seems to me to be an indicator of the wrong data-structure.

jasonbell 2021-05-19T12:03:20.014Z

Morning

fel-mazo 2021-05-19T12:41:44.014100Z

wow a let to define private bindings, quite cool

2021-05-19T13:16:35.014700Z

someone should write a book about let over lambda

2021-05-19T13:18:21.016100Z

I find I don't use map-vals as I'll often want to (into {] (map (fn [[k v]] [k (something-to-v-possibly-based-on-k k v)) my-map)

borkdude 2021-05-19T13:19:52.016200Z

;)

dominicm 2021-05-19T15:13:11.016700Z

Error: Unexpected ]

dominicm 2021-05-19T15:13:48.017Z

@otfrom I think you're looking for http://weavejester.github.io/medley/medley.core.html#var-map-kv-vals πŸ™‚

2021-05-19T15:14:32.017100Z

Nah, I type it right when paredit helps me

borkdude 2021-05-19T15:21:42.017600Z

I like it when paredit helps me. I don't like it when paredit prevents me from fixing a mistake.

borkdude 2021-05-19T15:22:09.018Z

My workaround is usually to go into text-mode and then fix it manually 😨

pez 2021-05-19T15:29:55.018500Z

How would it stop you from fixing a mistake?

borkdude 2021-05-19T15:32:39.018700Z

if you have something like this: ([)]

borkdude 2021-05-19T15:33:03.019100Z

there's just nothing I can do to fix it within paredit-mode, it doesn't let me

djm 2021-05-19T15:35:47.020100Z

C-u C-d lets you delete stuff, no?

raymcdermott 2021-05-19T15:35:58.020700Z

Isn't that the clj-kondo logo?

3
mccraigmccraig 2021-05-19T15:36:36.021700Z

similar with smartparens - you have to toggle smartparens-strict-mode afaik

borkdude 2021-05-19T15:36:40.021800Z

@djm_uk no, that doesn't work in that situation, at least not in my editor

borkdude 2021-05-19T15:36:56.022200Z

@mccraigmccraig ah that's the one

raymcdermott 2021-05-19T15:37:17.022600Z

@borkdude you probably should use a modern editor

2
borkdude 2021-05-19T15:37:26.022900Z

I like basic terminal editors

😝 1
borkdude 2021-05-19T15:39:12.023900Z

so tl;dr: I am using smartparens and I have to disable strict mode to be able to fix it

pez 2021-05-19T15:41:00.026100Z

Maybe @raymcdermott means Calva. Really hard to type that with Calva Paredit. But fixing it is easy. alt+backspace to delete stuff w/o balance check. And also, a lot of unbalanced stuff you can just backspace.

raymcdermott 2021-05-19T15:42:02.027Z

I'm assuming Calva is epic, also with Cursive you can easily switch between structural editing between paredit / parinfer / none

pez 2021-05-19T15:42:54.027600Z

Haha, but, yes, easy to switch to CaveMan mode in Calva.

😬 1
pez 2021-05-19T15:45:10.028200Z

smartparens works with html and stuff too, iirc?

djm 2021-05-19T15:52:31.028400Z

Fwiw, with Emacs + paredit, C-u C-d lets me fix that scenario. As does two lots of M-s (`paredit-splice-sexp`). No idea about smartparens - I couldn't make it work the same as paredit so gave up on it

mccraigmccraig 2021-05-19T15:58:26.029400Z

lol, C-u 0 C-d let me unbalance a sexp with smartparens, but also seems to have crashed my emacs πŸ™ˆ

πŸŽ‰ 1
1
2021-05-19T16:29:03.030400Z

Or you can just yank it and then C-q ( the right thing back in

2021-05-19T16:29:25.030900Z

(yanking w/o using select sexp or forward sexp being when I tend to mess up my parens)

βž• 1