Fork me on GitHub
#calva
<
2018-12-24
>
pez11:12:37

In Sweden Christmas Eve is the big thing with Christmas. Traditions vary some between families of course, but it’s common with some morning presents in the christmas sock so that the kids can make it through the long wait of opening the presents under the tree, which happens after Christmas dinner.

pez11:12:20

Merry Christmas all friends of Calva! (If you celebrate some other holiday this season I hope you have a merry time too, of course.)

🎅 12
pez11:12:28

In the spirit of Christmas I hope you’ll consider giving the Calva extensions some thumbs up and good words on the Visual Studio Marketplace: https://marketplace.visualstudio.com/search?term=Calva&amp;target=VSCode&amp;category=All%20categories&amp;sortBy=Relevance ❤️

slipset14:12:33

Thanks @pez for working on this! Much appreciated.

❤️ 4
mattly19:12:37

I'm actually going through the horrific account recovery process for my microsoft account just to give you a rating

mattly19:12:03

they force you to subscribe to an azure newsletter just for the privilege

❤️ 4
facepalm 4
pez19:12:28

Appreciated, @mattly !

mattly19:12:21

of course, you provide me with a home away from emacs when doom-emacs' develop branch breaks

mattly19:12:11

I also think it's really important for the clojure experience in a popular editor like VSCode to be great, to help attract people to the language

mattly19:12:08

proto-repl in Atom is nice, but, it seems abandoned, doesn't work well with anything but leiningen, and Atom seems to be losing mindshare to VSCode

mattly19:12:41

and I'm not going back to the mines of vim anytime soon, my love for vim emulations non-withstanding

mattly19:12:13

proto-repl has a neat tree-like explorer for data structures which I found useful while developing a query engine for an analytics platform

mattly19:12:28

it seems REBL is going to aim for that itch now though

pez19:12:28

ProtoREPL shows the way feature-wise. I hope we will be able to bring some of that goodness to vscode.

❤️ 8
mattly19:12:40

I've been playing around with other languages recently as well, Rust and Reason in particular, and I feel VSCode offers a better experience there, so it's nice having a single environment to keep things in

lilactown20:12:10

@pez I’m secretly developing a web-based REBL-esque thingy. we should pow-wow at some point when I have more done and you have time to see if we can make something real cool

parrot 8
pez20:12:30

Very secretly! 😀 I am all ears, anyway.

mseddon21:12:59

@lilactown 😄 that sounds brilliant. There is a lot of scope to do something very cool there, especially if it's easy to extend views somehow as an end user.

mattly21:12:15

does the calva: lint on save option, when disabled, disable linting altogether or does it lint on change?

mseddon21:12:16

@mattly Just looking at the code, it appears to prevent linting on opening too

mseddon21:12:46

if github is telling the truth, those are the only places where that configuration option (and linting) are called, but @pez would be the definitive answer, naturally 🙂

mseddon21:12:24

the calva.lintFile action should not be affected, from what I can see, so you should still be able to invoke it manually with Ctrl+Alt+V, or "Lint current file", but it seems that it should never happen without your explicit request.

mattly21:12:25

ah interesting

mattly21:12:06

I have the "Clojure Linter (Joker)" plugin installed as well, and wondering how they interact

mattly21:12:21

it seems to only lint on save

mseddon21:12:50

Calva has no knowledge of that extension, so unless it knows about calva (and if it's possible for vscode extensions to look at eachother's config) I guess they just do their own thing 🙂

mattly21:12:14

cool, thanks

mseddon21:12:23

np, is this causing an issue for you?

mattly21:12:05

eh, I was working up a big function and auto-save had saved halfway through because I was distracted by my environment, and the error stuck around until I manually saved

mattly21:12:26

it was highlighting the whole form as the source of the error that I had fixed

mseddon21:12:32

ah, yeah, in calva you would have to invoke "Lint Current File", which would fix it

mseddon21:12:47

there may be an isomorphic command in Clojure Linter (Joker), but I'm unfamiliar with it

mseddon21:12:00

but you'd need to tell both 😉

mattly21:12:32

heh, well, it's just different behavior from what I'm used to with my currently-broken emacs setup

mseddon21:12:59

😉 i love emacs, but boy can you break it

mattly21:12:00

I need to create a radar plot with all the various editors and the things I look for in them

mseddon21:12:05

it seems there is no contribution for a user invokeable command

mseddon21:12:10

so they should add one 😉

mseddon21:12:27

actually that would probably be pretty useful info

mseddon21:12:39

I'm sure I could contribute to that with my own personal preferences

mattly21:12:49

my biggest gripe about emacs is lack of a really usable terminal emulation

mseddon21:12:22

yeah eshell does not count

mattly21:12:37

i mean, eshell is nice, ansi-term is nice, but since they're so tied to the GPL you're not going to get libuvterm or whatever neovim is using in there

mseddon21:12:38

although I do like that it tries to emulate a posix sh under windows, which makes it nicer for me

mattly21:12:53

so, forget about running ncurses programs

mseddon21:12:09

yeah, dammit stallman. ironically the GPL exists because Symbolics stole all his code from the MIT lisp machine project. 😉

mseddon21:12:31

true story. funny how things work out.

mattly21:12:41

my biggest gripe about both VSCode and Atom is how difficult it is to keep your full config in git

mseddon21:12:03

yeah, it makes a mess, and as a (very newbie) extension developer, I find it's api... lacking.

mattly21:12:16

which for an editor introduced since the rise of git is pretty inexcusable

mseddon21:12:29

quite. I wonder if there is an issue for that?

mseddon21:12:48

I have problems with random source paths getting set absolute in my .vscode configs, do you have similar issues?

mseddon21:12:57

mostly it's poorly built plugins, but it's still annoying

mattly21:12:49

no, I haven't seen those

mseddon21:12:17

what do you run into? I wonder if there's an issue open already

mattly21:12:20

you mean, in general?

mseddon21:12:27

yeah, the git config thing

mattly21:12:46

oh, mostly keeping extensions in sync across machines

mattly21:12:01

I haven't found a good way to do that yet

mattly21:12:10

I can't use that sync plugin which relies on gists

mseddon21:12:24

so you mean global configs, not workspace configs?

mattly21:12:05

as I'm not going to sign into my personal github account from my tightly-locked-down-and-probably-rooted work machine

mseddon21:12:22

no that's stupid. you should be able to pull it in from a raw gist

mattly21:12:47

well I can pull it in but I can't push it back

mattly22:12:04

so like, I have a github user just for my work machine

mseddon22:12:07

I have some silly shell script that moves up my .emacs/init.el attached as an emacs interactive defun here

mattly22:12:17

and that user is a collaborator on my dotfiles repo

mattly22:12:42

which I've symlinked the vscode settings folder into

mattly22:12:54

but it still doesn't track extensions

mseddon22:12:13

how do you mean?

mattly22:12:19

there's no canonical list of extensions I can sync between machines and then tell it to "make it like that"

mattly22:12:45

basically I need the equivalent of a package.json or something

mseddon22:12:25

ah right, some enormous aggregate JSON file

mseddon22:12:01

ah, wait- it's not just CONFIG, the problem for you is you don't know what extensions to install, right?

mattly22:12:30

which, the way I think of it, extensions are part of the config

mseddon22:12:43

huh, that is an interesting and yet surely easy problem, you need to PM me and remind me of this in a few days after I sober up 😉

mseddon22:12:53

they are, surely, to any human, part of the config

mseddon22:12:46

I use a roaming profile so this one didn't bite me, but there should definitely be a decent way of doing this

mattly22:12:49

for the most part it's fine, I do different things on my work and personal machines and don't need f.e. the reasonML stuff or the Hugo CMS stuff on my work machine, nor the cucumber step definition stuff on my personal machine

mseddon22:12:53

so really you want an extension that lets you say 'hi, this is one to sync'

mattly22:12:57

but then it's like,

mattly22:12:33

I use the same emacs config on both machines and it's fine, and VSCode is at least sane about extension loading times unlike Atom

mseddon22:12:00

my init.el script explodes when i didn't melpa those extensions

mseddon22:12:19

but, i just futz about until the errors go away. That said, since I'm a contractor I tend to bring my own device, unless I have some silly air-gap policy, in which case it becomes exciting form filling in time anyway.

mseddon22:12:18

I abandoned atom and went back to emacs because it just randomly would tank performance horribly, which is a shame 😕

mattly22:12:19

yeah, I live the exciting life of a salaryman

mseddon22:12:53

it's a wise decision. contractors are the last to come in, and the first to get kicked off a project.

mattly22:12:55

actually work for the same company as lilactown so don't want to slam it too hard 😉

4
lilactown01:12:28

lol I have plenty to bitch about too! 😉

mseddon22:12:51

so okay, you're looking for a vscode plugin that can work out the extensions you need installed, and install them, right?

mseddon22:12:57

and then obviously sync your user level config.

mseddon22:12:10

via github gists

mseddon22:12:32

or.. some anonymous thing like pastebin so you can post new configs but at least get the setup you need.

mattly22:12:14

actually I'd prefer not to use gists, just files in a directory I can keep in git

mseddon22:12:25

oh. right.

mseddon22:12:45

yeah, and it could write a timestamp and work out if this repo has a later version

mseddon22:12:05

😮 there is a // in your json

mattly22:12:09

hm it hasn't synced my keybindings recently

mseddon22:12:11

i didn't realise vscode allowed that

mattly22:12:21

yeah it's nicely humane like that

mseddon22:12:41

I honestly don't need it to run through eval, but y'know. comments are nice guys.

mseddon22:12:07

hence edn.

mseddon22:12:20

actually JSON without Map and Set support feels a little.. 1998.

mattly22:12:25

anyone who suggests that humans should edit JSON is immediately suspect in my opinion

mattly22:12:08

JSON is why we can't have nice things

mseddon22:12:44

well. edn and clojure.reader should support #n= syntax like common lisp imo

mseddon22:12:52

but.. that's just my opinion. 😉

mattly22:12:18

I've been very happy with transit in the projects where it's been feasible to use it

mseddon22:12:34

yeah, but it should be the standard

mseddon22:12:48

I have to say though, I'm pretty happy so far with my experience of vscode extension dev. I wish I could just open a scratch buffer and start evaluating typescript in the main process and be allowed to destroy things if i'm an idiot

mseddon22:12:02

I'm sure I can write an extension for that...

mattly22:12:06

but sadly that's basically, places where my code doesn't have to talk to anyone else's code

mseddon22:12:26

yeah, that normalize all the things dance gets dull huh.

mseddon22:12:29

so, do you use calva at work daily I wonder?

mattly22:12:59

I spend more time than I would like in some typescript/react native code that I'm not super familiar with and the team that works on that code all uses VSCode and I haven't figured out how to make emacs play nicely with either JSX or lsp

mseddon22:12:12

😉 ah fun

mattly22:12:23

and really the only thing I find missing from that experience so far is magit

mseddon22:12:40

I /love/ magit!

mattly22:12:46

but magit is ... a pretty high bar, so

mseddon22:12:05

the problem is... i can't just throw emacs at millenials and go "hey. have at it."

mseddon22:12:18

they.. break. fundamentally inside.

mseddon22:12:34

it's unfair, so I thought it'd be better to try and get vscode up to par 😉

mattly22:12:34

when I get frustrated with emacs from time to time for my clojure work I come over to VSCode and kick the tires

mseddon22:12:57

I won't lie I am a big cider fan myself

mseddon22:12:18

but I think it's doable to raise the bar on vscode, and I don't think it's THAT much work

mattly22:12:31

I don't think it's the millenials you have to worry about there, it's the tide pod generation

mattly22:12:12

I like tig on the cli for git, use it from within the VSCode terminal, but it's no magit

mattly22:12:56

I've thought about building out a cli magit clone in rust, but I have so little time outside of work for code anymore, and I'm spending that on an app I'm working on that I want to sell

mseddon22:12:13

that would be awesome, yet I fully understand the lack of time thing

mseddon22:12:46

also, I don't really mean to sleight millennials, just the problem with emacs is the conventions are so arcane as to be unnecessarily cryptic these days

mseddon22:12:09

I often Ctrl+W and then watch a browser tab vanish before my eyes. 😉

mattly22:12:13

heh, yeah.

mattly22:12:31

and there seems to be this fetishization of the old ways in both emacs and vim land

mattly22:12:26

like, "we know everyone else settled on these terms for window & clipboard management like 30 years ago, but our terms predate those, damnit! USE THEM!"

mseddon22:12:35

there was a lot of misty eyes over the lispm's in the early 2000's, although as a former user you can totally toast your environment and its security is a joke 🙂

mseddon22:12:46

that said, there is gold in them there hills.

mseddon22:12:27

I think nav/datify and a perusal of https://dspace.mit.edu/handle/1721.1/6946 would extract it though

mseddon22:12:51

and looking at vscode, I've had to re-implement a lot of things for my upcoming calva-fmt patch to make it usable, which really should have been exposed by vscode

mseddon22:12:42

(it is not cool that I have to implement my own re-startable lexer that syncs with the edits in order to figure out if the line above is inside a multi-line string...)

mattly22:12:25

oh god, no it isn't

mseddon22:12:38

shrug this is software, everyone grab a shovel 😉

mseddon22:12:24

I could rely on their lexical info, but they.. uh.. went a bit weird. vscode internally stores the 'colour', not the 'type' of a token. whoops.

mseddon22:12:38

also that's... undocumented not for you private api.

mseddon22:12:09

it's fine, I have a fast robust system for that now, but it's silly that I had to spend a week on it so I could get to the part where I got to start doing what I needed.

mseddon22:12:58

emacs uses a slightly silly lisp-specific facility for a lot of it's lisp work, too, so it's not immune to this either.

mattly22:12:25

you know, this explains a lot

mattly22:12:05

I've noticed some slightly variant behavior with another extension I use for C stuff that varies based on my current theme

mattly22:12:09

it's weird and I just sort of wrote it off as the usual jank associated with cobbling together one's environment piecemeal from bits and bobs

mattly22:12:37

but if they're looking at the color of a token and not its type, that would explain the behavior

mattly22:12:45

I'll file a bug with them

mseddon22:12:49

aha, yeah. they may be peeking in internals

mattly22:12:20

I get the feeling the vscode API is more locked down than many would prefer

mseddon22:12:26

which is... y'know. fine. but I feel the data they store is wrong

mseddon22:12:43

oh I think we can release plugins that are using all manner of undocumented hell

mseddon22:12:56

it's not like the apple store, but that is still a scary proposition.

mseddon22:12:32

I feel rather than storing 'color', store 'token id' mapping to a string.. etc.

mseddon22:12:22

I'd been looking at LL(1) parsers that could do this in the 80's, but it seems they made it pretty generic. It's what Atom uses internally now.

mattly22:12:05

hopefully now that Microsoft owns Github we'll see a bit more collaboration from them on their editor efforts

mseddon22:12:26

it would be neat. handling breadcrumbs in some random language would be far less work imo

mattly22:12:30

the atom rewrite project known as Xray looks interesting

mseddon22:12:56

huh, I have not looked at that, thanks for the heads up!

mseddon23:12:28

I do have faith that vscode will get there though. It's just rather young

mseddon23:12:52

vscode was an easier proposition to me after suffering atom performance tanks, so I can see why they have architected it the way they have

mseddon23:12:23

but as much as I grumble about its immaturity, it's still only 3 years old 🙂

mattly23:12:52

kiddo's up from nap, see ya later

mseddon23:12:05

tata. merry christmas and all that 😉