Posted a link to HN: https://hn.algolia.com/?dateRange=all&page=0&prefix=true&query=show%20hn%20joyride%20vscode&sort=byDate&type=all Would be cool if we could get some Clojure discussion on HN today :)
Maybe specifially at @leif.eric.fredheim. ๐ This is from the Show HN guidelines: > Make sure your friends and users do not add booster comments in the thread. HN users are adept at picking up on those, they consider it spamming, and they will flame you for it. If a friend or a fan has something interesting to say, that's fine, but comments should not be promotional.
@pez Are you referring to me posting a comment with a link to your YouTube video on the HN thread? I would hope it's relevant and OK to post a demo of how it works.
@leif.eric.fredheim I think your video PR links to the wrong video btw ;)
I should have checked that before I merged it
Haha, @leif.eric.fredheim. I was more referring to your enthusiasm ๐
No offense intended. Just kidding around. I love that you are helping with this!
@borkdude Oh, shit! I'll recheck the video link. I thought I verified it, but I had several Calva videos open in different tabs and may have gotten things mixed up ๐ Apparently, I can't even be trusted to edit Markdown files, lol
@pez No worries! I just wanted to make sure I wasnโt unintentionally screwing things up on HN. I'm like a dog in a squirrel park, so I need to be leashed and reined in sometimes ๐
Huh, the video link now appears to work for me. Previously I saw the fizzbuzz video. Well, all is solved it seems then
Now itโs no. 3 on HN.
@borkdude Ah! I think I know what happened with the video linkโฆ There was another video link right below to the FizBuz video โบ๏ธ I suspect you might have clicked that one, thinking it was the one I added above. Not that it matters much, but maybe it solves the mystery.
ok, sorry for blaming it all on you ;)
Haha, no worries! ๐ There is always a decent chance I borked it.
Did someone mention my name? ;P
As a former software QA tester in the games industry, my job for half a decade was literally to break (test) stuff ๐
I complemented the heisen-video-link with an embedded video (a bit damaged in the compression down to under 10 mb, but it works, I think).
The README is a bit updated now. To embed a demo video and also mentioning the examples folder, and what you can find there. https://github.com/BetterThanTomorrow/joyride/blob/master/README.md
I think it is possible to embed youtube videos directly in the README
I've done this with babashka
oh no, that's not true, it only shows the preview in the README and when you click you go to youtube
but that seems actually good enough to me
I was trying to do that (albeit not very hard) and all the articles I found said it wasn't possible.
Beat me to it :)
But I think what PEZ has done is awesome, you can just stay in the README
I did it like that because w/o a play-button overlay it is not obvious enough that it is a video. But, yeah, actually now you stay in the document. That's a plus!
#2 now!
I made a rough example as a reaction on a question by someone on HN, how to read a number from the cursor, increment it and put it back into the document: https://gist.github.com/borkdude/08ec3ae2af5963a4a03cd8e0873c918d Instead it reads the number from the end of the line, else I wasn't able to interactively test it in the REPL ;)
I think maybe if you use replace instead of insert you can do it on the selection, interactively in the REPL.
but how do I select and also invoke a function from within the REPL without undoing the selection?
I'm not sure, but I think that replace retains the selection.
Took a quick look at Joyride README and it talks about to set it up you need to make a .joyride directory in your workspace. Is it possible to make a ~/.joyride directory as well to make globally available scripts rather than workspace-specific stuff?
@phdumaresq there is an issue about that, we call that "user scripts"
and this is something we want to get in for 0.0.3
I jotted down an idea that occurred to me. Or actually, while I typed it, it forked out to two ideas. But anyway: https://github.com/BetterThanTomorrow/joyride/discussions/14
Do you want some help on this feature? Sounds amazing, and it will make joyride quite the same as the Atom's init script...
It would be awesome with your help, @mauricio.szabo!
@pez I think that's a pretty interesting idea... what happens if you alter the manifest of an extension? It would require a reload I think right?
There could be one "managed" extension by joyride to which it flushes a package.json manifest. All the user has to do then is to reload it after joyride makes changes to it.
And that extension could live in ~/.joyride/foo.vsix or so
And building this foo.vsix extension should be completely reproducible from settings/scripts within the joyride config, so it can be properly synced
I'm afraid such a thing would require a vsce package + install action
Not sure why it would need vsce package? It just packages a zip file with some special content, doesn't it?
right, but it "installs" that package somewhere right?
maybe just invoking code ~/.joyride/foo.vsix is sufficient for that, but it feels hacky
We could just prompt the user that the side-car extension is out of date and you need to re-install it
when they e.g. update their joyride config and we detect that the generated extension isn't up to date anymore
I don't think code --install-extension ~/.joyride/foo.vsix is overly hacky. It's designed like that.
ok then :)
The only thing we need to require is that people have the command line thing on their path then, but that isn't an unreasonable ask
Maybe you don't even have to have that, if you can detect the binary from within vscode in some way
Maybe it's something that can be called via npx?
I don't think so,
but let's just assume that invoking a process with "code" will work
There is a VS Code command to install it. If that one is registered as command proper we could prompt and ask if it should be installed.
@lilactown you might like this
@lilactown has joined the channel
In some other Slack, far, far away. That's Eric Amodio, member of the VS Code team, and creator of amazing things like GitLens.
I answered him like so:
Thanks for such feedback! Some tools that can come in handy if you decide to Joyride VS Code, assuming you don't know Clojure all too well:
1. Calva has a command Fire up the Getting Started REPL that will guide you interactively into learning first some basic Calva, then some basic Clojure. Read about it here: https://calva.io/get-started-with-clojure/
2. Calva has a command for converting JavaScript to ClojureScript. So you can open a new window, type in the JavaScript that does what you want there. Issue the command and a new, untitled, document will open with the corresponding. ClojureScript. (It will often be missing some js/ name spacing for reaching the global object, but it can be a good start.) See here for a demo: https://www.youtube.com/watch?v=bMU2GhucLXc
I was talking with @nonrecursive earlier today and mentioned exactly this scenario, People who want to hack their VS Code in an interactive way might find Joyride interesting, and maybe even interesting enough to risk some time to learn a new, strange, language. And we happen to have created some other tools that can help with that! Now, I don't dare hope that Eric Amodio will really try it, that would be a bit too good to be true, but anyway, it's a datapoint.
it might be interesting as an intro to the vs code extension api, like the getting started repl
not that anyone here would want to do that but it's a neat idea for like microsoft to do
I would love to do it. Might do it actually!
One spelling issue: adn
Thanks! I merged a PR fixing this. Unfortunately won't be updated on the marketplace until 0.0.3.
Here's anther example: https://www.youtube.com/watch?v=V1oTf-1EchU You'll find it as .joyride/scripts/ignore_form.cljs here: https://github.com/BetterThanTomorrow/joyride/tree/master/examples
Already using it I always had to alt + key key key to go tho the start of the form and #_ it. gratitude
Thatโs awesome!
I do ctrl+up, like in the script. ๐ค
Clever hehe
Please help share this tweet around: https://twitter.com/pappapez/status/1519825664177807363