This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2023-03-22
Channels
- # alda (2)
- # announcements (1)
- # babashka (32)
- # beginners (67)
- # calva (1)
- # cider (19)
- # clerk (11)
- # clj-commons (35)
- # clj-kondo (7)
- # cljsrn (2)
- # clojure (35)
- # clojure-europe (86)
- # clojure-nl (5)
- # clojure-norway (5)
- # clojure-russia (6)
- # clojurescript (16)
- # clr (21)
- # conjure (1)
- # core-async (10)
- # cryogen (1)
- # cursive (12)
- # data-science (1)
- # emacs (29)
- # events (4)
- # figwheel-main (2)
- # graalvm (9)
- # gratitude (7)
- # honeysql (4)
- # hugsql (3)
- # hyperfiddle (23)
- # jobs (1)
- # jobs-discuss (4)
- # joyride (9)
- # malli (2)
- # off-topic (81)
- # portal (7)
- # reagent (19)
- # reitit (1)
- # releases (4)
- # shadow-cljs (121)
- # xtdb (3)
Has anyone here gone from normally working with music to working without it? If so, have you noticed a difference in productivity?
I love music, but I don't listen to it when I am doing work that requires my full attention. Following the logic of music seems to use a lot of the same resources that programming does, for me, so music makes me noticeably worse at programming.
My thinking has been that instrumental music is less distracting and is OK, but I've never seriously tried 0 music and comparing
I need music, or some sort of ambient sound, and it absolutely has to be instrumental/without words
I mainly listen to instrumental music (or choral music where I am not paying much attention to the words, and in many cases wouldn't understand them anyway) and it still interferes for me. I have put a lot of work into training myself to listen carefully to music though, and it might just be that I can't turn that off completely.
It might be worth giving no music a try, and seeing how it feels. Even if you aren't explicitly thinking "oh, we just modulated to a new key", on some level you are spending some cycles noticing that, if you are enjoying the effect of the modulation. But I imagine everyone is different in this respect, and I know great programmers who always listen to music while programming.
Depends on what i'm doing, I have a few records that help me with hard work. It's deep ambient, drone-like noise.
i really dig this guy's work, been listening for over 20 years to his work https://matthewflorianz.bandcamp.com/
My default is no music but agree with instrumental being ok. My favourite is the donkey kong country soundtrack on spotify
Really depends on the music and what I'm working on. Before getting in a state of flow it can be a distraction, after it can be a stimulant. Try to mix and match, I often start with pink noise then depending on the mood pull off something instrumental. The important bit is understanding that working with music is not a uniform experience, it can effect your productivity in both ways. The needle to thread is making sure you aren't listening to something which engages the same part of the brain you're trying to work with
I find music helps me get into a flow, especially Mike Oldfield, Lindsey Sterling and some Hawkwind If I have had to participate in particularly terrible meeting or received prolonged micro-management the I bring out Nyan Cat for a strange kind of stress relief https://www.youtube.com/watch?v=SkgTxQm9DWM
Music is fine as long as I already know it and like it. That being said, working without music is less stressful.
I see you nyan cat and raise you: https://www.youtube.com/watch?v=Ya1pDAOKyzk
https://musicforprogramming.net/latest/ Absolutely essential resource for me; largely beatless ambient, drone + electronic selections from a huge variety of musicians and programmers
My recent goto for electronic music (with lots of beats 🙂) is HÖR BERLIN
and Boiler Room
youtube channels
When I'm fully emerged and motivated I often don't need music. That's typically at later hours. (I'm very much a night owl, although I keep a normal sleep schedule.) During the day, especially when I feel a lack of drive, I almost need music to keep going at a steady pace. Even more so when the task at hand is not very mentally stimulating. When I need super high concentration, (problem solving, design, hard debugging) I automatically turn the music off. Almost subconsciously.
Experts may debate whether Beethoven liked to work while listening to Yanni or Cusco. But there can be no doubt that some of his finest compositions were completed after his hearing had been taken away and the music was only in his head. Let us also remember how Rich Hickey exhorted the crowd at a Conj: "Design like Bartok! Code like Coltrane!" A work of pattern and harmony is what we are making.
Yes and yes. I'm more focused without music. After the start of COVID and with a completely silent home office I stopped listening to music while working. Before that I've used music to "drown out" noise, on and off. I've been fortunate enough to have a private office* (with a door I can close) at work for a few years. It's been great for concentration. My workplace is relocating a few hundred meters, and in that process most of the workforce, including me, are loosing our private offices. :-( • Not sure it's the correct term. "Cellekontor" in Norwegian.
https://github.com/artempyanykh/marksman Has anyone ever used this library? It's a "networked note-taking" tool similar to Roam, Obsidian, etc, but designed to be editor-agnostic. At first glance, implementing its features with LSP seems like a very compelling design choice: not only does it make the tool editor-independent, but other tooling that uses LSP could build on top of it in a much simpler way than the "plugin API" that other similar tools provide (which makes me wonder has anyone built a Clojure client for a LSP server)?
A clojure client for a LSP server is exactly what https://github.com/clojure-lsp/lsp4cljis :) A way to create both servers and clients via clojure
anyone have good resources for setting up a dev environment on windows? I’m inheriting my wife’s old computer and hoping to treat Windows as essentially a window manager and everything else in wsl2 (i guess?). Interested to hear experiences/guides of how you manage files and projects (clone natively in wsl2? mount some subset of C:\ in wsl?), running your editor (emacs, in my case, interested in vs code and cursive as well. do you install them in windows and point them at the linux folders, etc?). Love to read any blogs or resources you may have used to make a modern windows dev setup
Do everything natively in WSL2 if possible.
do you run vs code from linux? I think it can run gui applications now right? And you don’t have to setup your own x11 server?
Both my work and OSS machines are Windows with WSL2 now. With VS Code and the WSL extension, editing -- and Calva etc -- is all seamless. All my code runs on WSL2 (Ubuntu 20.04 right now). Yes, Firefox and Chrome can run on WSL2 and display on Windows.
All built-in and it works great.
So I basically treat it as a Linux machine, that happens to run some apps on Windows 🙂
> With VS Code and the WSL extension, editing -- and Calva etc -- is all seamless. does this mean you installed windows version of them and they are “aware” in some sense of wsl2? Or are they installed in linux and run from linux?
Windows VS Code, yes. It installs a little server on WSL2 to communicate. It adds a code
command on Linux.
I've been reluctantly using windows for years. I personally have always preferred just using windows proper and skipping wsl. Things like emacs/clojure/java are pretty easy to install and get working as they would on linux. I sorta like the scoop package manager.
So I do code /path/to/my/repo
in Linux and up pops the Windows version of VS Code focused on that folder. It's so smooth it's like magic 🙂
@U064UGEUQ that’s interesting. I might look into that. You’re right that emacs and java have first class support on windows. But powershell and clj
are not really the best of friends so I’ll probably try a wsl2 life first
And if you do code somefile.clj
, it opens in the most recent VS Code instance you already used, alongside whatever project you had open.
clj
just makes Clojure a simple (in principle) class path creator and gets out of your way. Don’t want to go back to the before times
VS Code "jack-in" works too -- starting a REPL on Linux and connecting to it from Windows.
I don't know what editor(s) you use today @U11BV7MTK?
oh yeah the powershell struggle is real, if you're calling clojure cli programs with args you need to quote, it's probably a dead end. but I've found I've mostly been able to work around it
emacs only for Clojure. I’d look at vs code if there was still a good socket repl client. I’ve gotten used to bare tools and don’t fancy going back to nrepl
Ah, then you'll probably just run Emacs on Linux I expect?
yeah that’s my guess. i set up an alias and just e .
and it opens my running emacs with that directory. And with no need to run an x11 server hopefully It Just Works™
didn’t know about file systems. if there was any attempt to mount directories in both worlds. But it sounds like you treat it like you are ssh’ing into your linux box that has cheap x11 port forwarding and deal with it like that
/mnt/c
in Linux is your Windows C: drive, and Windows can also explore the Linux filesystem as I recall but I almost never use that path...
I've had to run emacs directly from a windows build because my programs need to inherit permissions from the windows environment and the experience is ... less than ideal. Would recommend sticking to wsl if you can
I could never get cider-jack-in
to work, for example, so I always launch a nrepl server from powershell and just use cider-connect
, emacs is rather slow to start, etc
Maybe last thing. If my project runs on local host 3000 in wsl, how do I get there in a browser? Run a browser in wsl or a browser in windows and some translation to the vm ip?
I tend to run firefox
on Linux and accept the X11 ugliness of it 🙂
There is a way to access a server on WSL2 from Windows but I can never remember/be bothered to set it up 🙂
The defaults in wsl2 should allow localhost bindings in linux to just work from Windows
It is a VM. The linux to windows forwarding is done automatically. If you want to access windows services from WSL or WSL services from an external machine it’s more involved. https://learn.microsoft.com/en-us/windows/wsl/networking
ahh. maybe that’s where i got turned around. thanks @U015879P2F8
I just tried running VS Code on a local (Windows) project and connecting to an nREPL server running on Windows: localhost
did not work, I had to use the IP of the WSL2 VM (192.168...), and I had to be sure to start nREPL with --bind "0.0.0.0"
for that to work.
So, yeah, as long as your server processes bind to 0.0.0.0 then you can access them from Windows via the VM's IP (which I got with ifconfig
).
If you want an arch distro without the setup hassle, I am using EndeavourOS for wsl2. it's working perfectly fine. Accessing localhost is no problem from windows at all. Even docker/podman is working like it was one machine.
Since you've got some answers I would like to challenge the assumptions of your original question and ask you to consider the option of switching to a 100% GNU/Linux distribution. 🙂 Windows feels like an unnecessary middleman to me and even though Linux WMs/DEs can be a bit rough around the edges compared to Windows, they've gotten better (and keep improving) ime and, well, you get a native -and libre, if you care about that- system which immediately gets rid of all "how do I make windows/WSL communicate with each other?" questions.
I recently killed some time setting up a dev environment on Windows (back on a Windows PC after a decade or so). See if this helps https://www.linkedin.com/posts/sunilnimmagadda_port-activity-7009930248083402752-4ZSh?utm_source=share&utm_medium=member_desktop You can skip every NetBSD/Hyper-V bit if you choose wsl2.
@U11BV7MTK Here is a blog + talk I did on that subject: https://blog.michielborkent.nl/remote-wsl2-clojure.html
For installing clj on Windows I recommend scoop + scoop-clojure + clj-deps
(which is based on deps.clj renamed to clj.exe)
In addition to coding I want to play racing games :) I have a windows partition on my intel Mac and I can only hold one modern game at a time. And to install F1 2021 I had to disable swap and suspend on windows. So hear you on all Linux but need the gaming
So the results are in. Emacs built from source, can visit the wsl localhost:3000 from windows without having to do any special tricks. The one remaining issue is that when the computer wakes from suspend emacs gui program seemed to have disappeared. the job was still running just not visible anywhere. Very close to a great setup
Yeah, I seem to recall some limitations with the X11 support and sleep/wake. I only use browsers from Linux and don't leave them running - because X11 versions of GUIs are just so ugly to work with. I can't imagine using an editor that way all day long:scream:
But I tried other X server tools before with the same issues as I recall
strange you can't use a native windows browser. I did zero configuration and it worked
A combination of being too lazy to set up the Windows hosts file properly and not having my Linux server processes binding to 0.0.0.0 I think:grin:
Our system all works off domain names (host headers)
And we have nginx in the mix and a bunch of port mappings too...
What I have works well enough for what I need so I haven't felt enough pain to dig into things (and don't want to mess with Windows much). And VS Code on Windows makes editing so nice:smile_cat:
I used Emacs on and off for close to thirty years but wouldn't go back to it now
My experience with WSL2 has been not so great. Mainly slow networking issues, etc, so whenever I've used Windows I've just set-up an actual VM using Virtualbox and the latest Ubuntu Server image, and forwarded ports from there to the main OS, that way I get an actual Linux. My $0.02.