Programming

23394 readers
122 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities !webdev@programming.dev



founded 2 years ago
MODERATORS
1
 
 

Hi all, I'm relatively new to this instance but reading through the instance docs I found:

Donations are currently made using snowe’s github sponsors page. If you get another place to donate that is not this it is fake and should be reported to us.

Going to the sponsor page we see the following goal:

@snowe2010's goal is to earn $200 per month

pay for our 📫 SendGrid Account: $20 a month 💻 Vultr VPS for prod and beta sites: Prod is $115-130 a month, beta is $6-10 a month 👩🏼 Paying our admins and devops any amount ◀️ Upgrade tailscale membership: $6-? dollars a month (depends on number of users) Add in better server infrastructure including paid account for Pulsetic and Graphana. Add in better server backups, and be able to expand the team so that it's not so small.

Currently only 30% of the goal to break-even is being met. Please consider setting up a sponsorship, even if it just $1. Decentralized platforms are great but they still have real costs behind the scenes.

Note: I'm not affiliated with the admin team, just sharing something I noticed.

2
 
 

When publishing a package for use by programmers, automated changelog generation is very beneficial. In this blog post, I explore how to do it in a simple way that works everywhere.

3
 
 

Hi everybody, this is the JPlus development team.

JPlus is a Java superset programming language, extending standard Java syntax with additional features. So far, we have introduced null-safety and boilerplate code generation features. Currently, we are planning to add Named Parameter support to JPlus. This feature allows specifying parameter names explicitly when calling methods or constructors.

The point we would like to discuss is whether to support Default Values.

Option A: Named Parameter only

  • Pros: Simpler syntax, minimal implementation and learning overhead

  • Cons: Call sites may become longer in some situations

Option B: Named Parameter + Default Value

  • Pros: More concise code, allows omitting some arguments when calling

  • Cons: Can make code slightly harder to read if too many defaults are used

We would like to gather opinions on whether default values are truly necessary in practical coding scenarios.

If you want to learn more about JPlus, please refer to the links below:

4
8
Against SQL (www.scattered-thoughts.net)
5
 
 

I’ve tried vim on and off during college but never really had the time to fully get working with it. As it turns out the stress of two degrees is not conducive to “fun activities”. Now that I have a real job ™️, I’ve decided to finally try and use it this week full stop and I genuinely feel like a programming chad. There’s still a lot I’ll need to learn and probably overtime I’ll discover some inefficiency in how I’m using it now but it really does just feel good. I understand the hype now.

6
 
 

JPlus is fully compatible with Java, offering modern language features like null safety, boilerplate code generation and other modern language features to reduce developer burden and maximize productivity.

Notably, there is currently no ‘superset’ language that keeps Java syntax almost intact while extending the language with features like null checks at the language level. JPlus aims to fill this gap, providing a language that existing Java developers can naturally learn and adopt.

7
 
 

JPlus is fully compatible with Java, offering modern language features like null safety, boilerplate code generation and other modern language features to reduce developer burden and maximize productivity.

Notably, there is currently no ‘superset’ language that keeps Java syntax almost intact while extending the language with features like null checks at the language level. JPlus aims to fill this gap, providing a language that existing Java developers can naturally learn and adopt.

8
 
 

A very small thing just happened to me that I don't think I would have noticed if I hadn't been specifically trying not to use an LLM coding assistant.

I am trying to teach myself Godot and GDScript. I have some ideas for video games that I've had scribbled down for a while now but I'd never built enough of them to get a satisfactory prototype. I am comfortable enough in JS that I've now cobbled together some Phaser code into a working game, but I used an LLM to write most of it, I tweaked it just enough to get it running because I wanted a working prototype more than I wanted something polished. I was able to do this pretty quickly, but I (quickly) ran into the problem a lot of vibe coders run into, which is that I didn't understand how the code actually worked. Debugging began to slow me down because I had to try to learn the code as I was debugging it. It was the difference between the relatively minor hassle of debugging my own code and the usually onerous, occasionally nightmarishly unpleasant chore of trying to debug someone else's code, where you keep having to context switch from "how could this code be producing that behavior" mode to "what is this code even supposed to do" mode. I didn't want to work on the project after a certain complexity boundary because making changes became exactly like one of the least enjoyable parts of my job, having to sift through huge amounts of unfamiliar code trying to cobble together enough context to enable the one minor change I want (then rinse, repeat).

So, I decided to start over in Godot, write in GDScript, use only the Godot editor, and use no LLMs while I figure out how to tell Godot what I want. Just me, the docs, and stack overflow, just like old days. Progress has been predictably slow, but I like it. Something about transitioning from generating huge blocks of code at a time and ripping through a generate -> edit -> test -> repeat cycle to writing everything by hand puts the slowness of it in a new light. This feel presumptuous to say because I know almost nothing about carpentry but it's what I imagine it might feel like going from a day job where you have to crank out furniture pieces as fast as possible, then going home to your woodshop and spending a few hours with the hand tools, getting one piece just so. Something about having a comparison to the new way makes the old way feel more noticeably nicer.

While I am doing this old-fashioned coding, I am reading a lot more than I'm writing as usual for starting out in a new language. I'm also less familiar with resources that are available for Godot, so I spend more time scanning the internet trying to find the bit that answers the question I have. Just now I was looking up whether there's a Tuple type in GDScript and I saw an example that, while it used an Array instead of a Tuple, also used the built-in Vector type. It wasn't what I was looking for, and it didn't solve the immediate problem at hand, but for the game I'm imagining I will almost certainly make use of Vector, so I made a note of it. And it occurred to me that this is a thing that happens a lot. I think that slow, semi-random accumulation of trivia and knowledge that happens over the years while you're poring over old forum threads or rambling tutorials or ancient StackOverflow arguments is really useful for developing a deeper understanding of the tools you're using, and I don't think I ever appreciated it or even noticed it happening until now.

9
10
 
 

At some point I plan to implement (yearly) subscriptions in my app and I'd like to use an European alternative to Stripe.

Having an Elixir SDK would be nice, though it's fine if there isn't one.

11
 
 

The two key points:

  • Meetings, interruptions, review delays, and slow CI pipelines cost more than AI saves. Individual productivity tools can’t fix organisational dysfunction.
  • AI amplifies existing engineering culture. Strong quality practices get faster. Weak practices accumulate debt faster.
12
13
14
 
 

As a Java engineer in the web development industry for several years now, having heard multiple times that X is good because of SOLID principles or Y is bad because it breaks SOLID principles, and having to memorize the "good" ways to do everything before an interview etc, I find it harder and harder to do when I really start to dive into the real reason I'm doing something in a particular way.

One example is creating an interface for every goddamn class I make because of "loose coupling" when in reality none of these classes are ever going to have an alternative implementation.

Also the more I get into languages like Rust, the more these doubts are increasing and leading me to believe that most of it is just dogma that has gone far beyond its initial motivations and goals and is now just a mindless OOP circlejerk.

There are definitely occasions when these principles do make sense, especially in an OOP environment, and they can also make some design patterns really satisfying and easy.

What are your opinions on this?

15
 
 

Does anyone have a favorite diff tool for reviewing lots of code? I'm thinking something along the lines like meld or vimdiff. I don't really need a git client. I'm comfortable with the git CLI. I'm mainly interested in making code reviews a little easier to manage.

I'm reviewing a large code change right now and the web interface sucks. It's slow. It doesn't load all the files at once. Cross referencing files sucks.

I know, I know. "Code changes should be small." I've already voiced that to my team, yet here we are. I'm trying to figure out a way to make this a little less miserable.

16
 
 

Obs.: I'm using "[REDACTED]" to not look like I'm doing some advertising.

Sorry to bring AI subject here, but I'm terrified by how efficient AI generation code became in the past few years.

Last year I was seeing a designer community with desperate people because of AI generative images, many people hopeless because how more convenient it is, way more than paying for a freelance to do something reasonable.

Now I'm with the same feeling as a programmer. I just decided to take a look into AI a little deeper, as I don't use it very often. So I tried the recent [REDACTED] editor, which is just [REDACTED] with AI agent features (an AI that does more than just generate text, it create files, make decisions etc...). And I must say, programming jobs will be reduced a lot.

The app was able to do a entire module of a side project, integrating with another API and following the same conventions I did. It worked in the first try. It created all the files and everything.

Many people bring this argument: AI won't replace devs, we'll always need devs to check code etc. Ok, I agree with that, but if before we needed 5 devs to do a job, now we just need 1 to revise all the job an AI did alone equivalent to 5 devs programming.

So, there's no way it won't impact the devs market. I'm being optimistic here, because the future is still unclear, but if it keeps the same rate we can reduce the dev jobs to near zero.

This is what every executive always wanted, get rid of devs, and now they can. Devs were always an inconvenience to executives, but they couldn't get the job done without devs.

Now they can focus all money on AI research until it gets nearly perfect, reduce the skill needed to deal with code and build projects without too much knowledge, and get rid of many devs too.

It's undeniable that AI jobs WILL be affected in a negative way. I'm seriously considering leaving this area and use programming just as a hobby, nothing more.

17
18
19
 
 

I’m experimenting with where I want to host tech blogs, but I put this short one on Write Freely

https://blog.keyboardvagabond.com/michael-dileos-software-and-tech-blog/longhorns-backup-cost-savings-or-not-getting-surprise-bills

tl;dr - my S3 storage costs were at $26/month more than I expected due to Longhorn (storage volume management for kubernetes) making over 5M s3_list_objects calls. Turning off that polling should fix it.

20
21
 
 

Can kids under 10 be possibly taught coding, without even mentioning the word syntax to them ??🤔🤔🤔

22
23
 
 

From the video description:

Stop recompiling your C code just to change a number. adjust.h is a single-header library that lets you edit variables while your program is running - no rebuilds needed. Just include the header, mark your variables, and watch them update live as you edit your source file. In this video, I'll show you how to set it up and demonstrate why this simple tool can save you time.

Works with any C99 compiler and integrates perfectly with Raylib, ImGui, and other popular libraries. Whether you're tweaking game physics, adjusting graphics parameters, or fine-tuning algorithms, adjust.h will make your life simpler. Zero dependencies, minimal setup, maximum productivity.

24
 
 

I always see the programmer sentiment that "people should not be using excel for (project). It should be a database."

I am guessing by that they mean SQL? I dont know a thing about that except the acronym. The most ive done is a basic linux script and 2 hours of a VBA course. I suck at understanding programming, so id like to understand exactly how one uses a database vs excel. Like whay are the actual steps id have to do?

25
 
 

What could be the best way to introduce the world of computers to a kid, let's say of 6 years old, so that he learns to handle it like a toy and stops dreading it like some esoteric, arcane and recondite machine from some eldritch, enigmatic, cryptic and phantasmal world ?

view more: next ›