Details
-
AboutProgramming is a lot like a marriage.
-
SkillsWriting comments
-
LocationIreland
Joined devRant on 12/11/2016
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
-
Manager: Write a function to get tomorrow's date.
Kids:
int getTomorrowsDate() {
return getCurrentDate() + 1;
}
Legends:
int getTomorrowsDate() {
sleep(1000*60*60*24);
return getCurrentDate();
}14 -
I don't understand why so many people fight this war of tabs vs spaces. My colleagues elegantly solved the problem just not using indentation at all36
-
IntelliJ IDEA just saved my ass!
I tried deleting a resource file I had staged, but not commited yet.
A dialog comes up asking to delete alternative configs with "Yes" as the default.
Boom! After I braindead hit the enter key all other files vanished too!
I checked Git and saw to my horror that the files were also not tracked anymore.
I hastly lookup the last backup timestamp - an hour ago - fuuuuu!
I just lost about an hour of work.
I was about to give up and start from scratch when I look at the edit menu in my IDE.
Turns out you can actually undo multiple file deletions!
Kudos to the girls and boys at JetBrains! You saved the day! 😙8 -
Always use SELECT-query with the same conditions before you DELETE/UPDATE in a production database.1
-
At first I was like: "wtf just happened? Why is that hand connected like it was a robot?".
.
.
.
.
.
.
.
Then I realised it's a watch.9 -
There is code reuse and then there is stupidity. This npm module has 4 dependents and 2 dependencies.18
-
Client asked to change the shade of blue to a little lighter shade. Deleted the hex code and typed the same hex code again and showed it to him. Instantly approved.8
-
Recently wrote a script that would check 2 years worth of images, crop them, and resize to different sizes as changes to front end required those.
Eventually the script went into an infinite loop and crashed the whole CMS.
The worst part was that my manager was on a date and I had to call him back into office, since his laptop was still at the office.
The actual problem wasn't the loop.. I forgot to check if file actually exists before cropping... Error log size was 10gb!1 -
At Google headquarters:
"Today seems to be a bright day"
*Angular 5 is out*
"Sir, I need to change something small, shall I do a pull?"
*Angular 6 is out*
"It's Pichai's birthday today!"
*Angular 7 is out*
"Wussup"
*Angular 8 is out*6 -
During a software presentation for a group of clients i said:
"I reworked the interface for you. Now it's idiot-proof."9 -
My girlfriend comes in and sees me on devrant.
GF: "What is that app? I see you using it all the time. Is it like an endless blog with updates?"
Me: "It's kinda like facebook. But for developers. And you don't have any friends".
GF: "That seems like a sad app"37