News for hackers. Stuff that matters.
Re:Nim 1.4 by tylorr on Friday October 16, 2020 @02:00PM (#24803325)
What's the dev experience been like? Do you feel like there is good editor support for debugging and such?
Re:Nim 1.4 by nivviv on Friday October 16, 2020 @02:08PM (#24803395)
I've been using vscode+nim. Debugging was mostly just writing correct code in the first place! ;) The only gripe I have is sometimes nimsuggest hanging itself at 100% cpu use, and I have to kill it manually.

Even with the rather oldschool approach of echo/logging.nim usage, things tend to turn around quickly. I have not felt the need to be able to attach a debugger to the process, mostly because our architecture is very pluggable. Almost all events/interactions are on a message bus and can be hooked/handled individually.

Re:Nim 1.4 by elcritch on Friday October 16, 2020 @02:29PM (#24803600)
https://nim-lang.org/blog/2017/10/02/documenting-profiling-a... -- Not sure how good the VSCode debugging integration is, but all the requirements are there including gdb/lldb. Word is JetBrains folk wrote a new Nim plugin too. Personally, I like the `writeStackTrace` bit.
Re:Nim 1.4 by jimbob45 on Friday October 16, 2020 @02:24PM (#24803549)
What build system are you using if not MSBuild then?
Re:Nim 1.4 by nivviv on Friday October 16, 2020 @02:28PM (#24803595)
Our production stuff runs on Linux, so we just wrap it into docker and that's that.

Personally, I develop on Mac and it runs natively there the same as on Linux.

Windows binaries for the tooling releases I used to build with a cross-compiler, but more recently, GH actions looks attractive enough to take that role.

Edit: Sorry, could have been clearer. The build system is just running the binary directly via nim cpp -r in development, and for production it's nimble. The dockerfile is handcrafted, but of trivial complexity.

Re:Nim 1.4 by jimbob45 on Friday October 16, 2020 @02:39PM (#24803715)
So you use Docker to keep the build system unchanged between builds? That’s genius if so and cuts deeply into MSBuild’s main advantage (comprehensively delineated system settings).
Re:Nim 1.4 by nivviv on Friday October 16, 2020 @02:53PM (#24803844)
I think there might be a misunderstanding. I'm just talking about the multiplayer service infrastructure, not the whole game.

Despite doing a lot and having a lot of smaller moving parts, the mp infra is of moderate code size and build complexity is not a concern. The whole thing compiles in less than 5 minutes, and can be done with nimble (the package manager). We have a docker builder image that spits out the final production image containing the apps, and a docker-compose setup then runs those as needed.

Any kind of per-platform specifics are handled in nim itself (when defined(Linux): etc) and via nim.config/nims.nim, to link in platform libraries.

Re:Nim 1.4 by federico_c on Friday October 16, 2020 @05:13PM (#24805109)
I use the Nim and GCC compilers from Debian in order to have guaranteed stable build system for 5+ years.