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
Search - "diff"
-
When you stare into git, git stares back.
It's fucking infinite.
Me 2 years ago:
"uh was it git fetch or git pull?"
Me 1 year ago:
"Look, I printed these 5 git commands on a laptop sticker, this is all I need for my workflow! branch, pull, commit, merge, push! Git is easy!"
Me now:
"Hold my beer, I'll just do git format-patch -k --stdout HEAD..feature -- script.js | git am -3 -k to steal that file from your branch, then git rebase master && git rebase -i HEAD~$(git rev-list --count master..HEAD) to clean up the commit messages, and a git branch --merged | grep -v "\*" | xargs -n 1 git branch -d to clean up the branches, oh lets see how many words you've added with git diff --word-diff=porcelain | grep -e '^+[^+]' | wc -w, hmm maybe I should alias some of this stuff..."
Do you have any git tricks/favorites which you use so often that you've aliased them?50 -
Manager: This button is too dark, you need to lighten it. Have you no sense of design?
Dev: …
Dev: Hows this for an adjustment?
Manager: Wayyyyy too light now, jesus you need glasses if you think that’s good.
Dev: …
Dev: How about now?
Manager: It’s close, make it just a little more dark. God why does this have to take so long, do I have to hold your hand through this entire process!
Dev: …
Dev: There that good?
Manager: Yes that’s perfect! Send me a PR immediately so I can approve, we need to get this out ASAP, it’s critical!!
Dev: I can’t.
Manager: ????
Dev: There’s no diff, you had me gradually adjust the colour back to exactly what it was originally.
Manager: THAT’S IMPOSSIBLE IT LOOKS COMPLETELY DIFFERENT. HOW DARE YOU INSULT ME LIKE THIS, I HAVE A MEETING I NEED TO GET OFF TO BUT WE WILL BE HAVING WORDS LATER ABOUT THIS INAPPROPRIATE BEHAVIOUR.
Dev: …16 -
A couple of months back I got an interview for a junior android devel position. I do not consider myself a junior devel, bt fuck it they paid 78k a year plus benefits and this is for south texas where it ain't thaaat expensive. So i kept my mouth shut and went with it.
The company was glorious, one of those hipsert marketing companies with cool couches and shit and people doing fuckign whatever all over the place and cool tools and desks.
So the initial interview with the hr dept went amazing, real cool guys and very down to earth. Next was the senior android dev.
This dude.
It was to be a phone interview, with a lil coding test. Fine whatevs. But the moment he called i knew shit was going down hill. Dude sounded dead af. Like he could not stand being himself that day. Asked asshole questions that every developer in Android should know that were frankly quite insulting ("what company develops the Android os" kind of deal) but kept my mouth shut and answered as needed.
Then the coding portion. Given a string, find the first position of the first repeated char, so if I had , fuck i dunno "tetas" then t was the first (and only) char repeated and it should have given out 2.
Legit finished it up in less than 6 mins and only because he was making me explain my entire thought process.
He got angry for some reason. Mind you I speak like a hippie, with a melow town and calm voice all the damned time, got that Texas swag going on as well as any good ol' boy from Texas should right?
Well this dude was not having none of that shit that day.
Dude was all like "ok now....why exactly did you do it this way?"
With a VERY condescending tone. And i explained that at first I normally think about solutions in pseudocode, so I wrote that as well...1 min or less. In python. This is after I still had the Java solution on screen with perfectly clean and working Java. I saif that since Python was as close to pseudocode as it gets that I figured i would just write the "pseudocode" in python and then map it to Java with all the required modifications.
"Welk i did not ask you to write it in java, so i dunno why you would even do that to begin with"
That is one of many asshole remarks. The first when I mentioned that I found React Native good for prototyping complex ideas for FUCKING FUN. Passion motherfucker. Shit so fly I do it for fun. "We don't deal with that here so I am not interested in what you can do with that or how would it help me"
Mofocka plz.
Well going back to the python shit. I explain (calmly) that it was just a way that I had to figure details, to think of different implementations. He continues by saying that it takes valuable company time.
Then he proceeds to tell me that he believes that i cheated since i fi ished the java "problem" too fast.
I told him that simple stuff like that should take even less for any senior java dev and that we could run another example if he wanted.
Bring it puto.
But no.
He then said that he still did not understand the need for Python in my solution. I lost it.
"Look man, getting real tired of your tone, i explained already, it is just a mental process, i do this when comming up with solutions, thinking in theory, not languages, helps me bridge the gap between problem and implementation, the solution works, it is efficient and fast and i can do it in 5 diff ways if you wanted, i offered and you said no. Don't really know what else you want"
"All i am saying, i am not going to hire you if you are going to be writing Python for Android, that is useless to me"
Lost it more.
I do sound different when pissed. So I basically told him that he asked for my reasoning behind and it was given, that not getting it was a you problem.
Sooooo did not get the job. Was relieved really. Can't imagine having a twat like that as a lead devel.19 -
I have what seems to be an unpopular opinion about buying software as a software developer.
First off, I support open source all the way. There should always be free and open tools for people to use if the need or want to.
Second, if you underpaid, broke, unemployed, or a student then this doesn’t apply to you. You keep pushing forward!
With that said, let’s get to the meat of it all...
I pay for good software. Even when it is expensive. Even when there are “workable” free or open source solutions.
I do this for a number of reasons...
1. They are better, hands down.
(Tower > GitKraken, SourceTree, GitHub Desktop) (Kalidascope > every other diff tool) (JetBrains IDEs > Atom, Brackets ...)
2. I’m no longer a broke student. I make enough money to buy them.
3. Most important: I’m a fucking professional software developer, not a fucking joker.
- If I was a carpenter then I could always hammer nails with the back of my work boot. It’s free and paid for and will do the job. Instead I would buy a good hammer because I’d be a professional and not a fucking joker complaining about the price of the tools to do my job.
4. I use a Mac, sometimes Linux and NEVER Windows. Which means I have a platform that actually has useful apps built for developers who are willing to pay for it.
5. I don’t get caught up in developer circle jerks about how all development software should be open source and free.
————
So there you go.
Does this offend you?
Good!
Come at me bro23 -
All Terms of Services agreement changes, etc. need to be in GitHub. I don't want to reread the whole thing, where's the diff?4
-
Code works.
Rename a variable for clarity.
Third-party lib behaves differently, breaks things.
Change the var names back.
Still broken.
Stash changes and checkout previous commit.
Everything works.
Diff with stash.
No notable changes. (some comments, ...)
Checkout branch again, pop stash.
Broken again.
... What?19 -
Recruiter: are you interested in a client side java role?
Me: yes, here is my client side resume please submit me
Recruiter: sorry the hiring manager said they are looking for more of a back-end engineer
Me: you told me it was a client side role, please resubmit me with my back-end geared resume
Recruiter: yes that's correct, it's client side, we'll keep you in mind for the future but you should know there is a difference between mobile devs and web devs
Me: what you just said is not relevant to this conversation. I would be happy to discuss the diff between front-end and back-end, client vs server, etc.
Recruiter: I'm just relaying what the hiring manager is saying to me
Me: your [lack of] ability to relay technical information is quite apparent :/
*lesson learned*: interview recruiters before they start interviewing me
Unbelievable waste of time, how do these people even make a living? FML!16 -
Don't do "git pull" quickly. Always do a "git fetch" THEN "git log HEAD..origin" OR "git log -p HEAD..origin". It is like previewing first what you will "git pull".
OR something like (example):
- git fetch
- git diff origin/master
- git pull --rebase origin master
Sometimes it is a trap, you will pull other unknown or unwanted files that will cause some errors after quickly doing a git pull when working in a team. Better safe than sorry.
Other tips and tricks related are welcome 😀
Credits: https://stackoverflow.com/questions...5 -
I once reviewed a Pull Request made by a fairly junior developer. They had joined recently, and this was one of the first times they had to touch a bigger part of the code.
Due to a mix of inexperience, new (to them) coding standards and lack of git knowledge, they ended up with a mess of a PR, with a few thousand lines changed, and no way to split it off.
I ended up spending the best part of a day reviewing the whole thing and requesting changes.
Even with the long list of improvements, however, I wasn't sure they would get the magnitude of their fuckup.
So I decided to use a real-world, palpable way to show them what they had done: I went and printed the github diff for that PR. It rendered the glorious amount of 73 pages.
I'll never forget their face, and those of their teammates, when I barged into the room with a thick wad of paper and deposited them on their desk.
At least it worked. I never saw another big, ill-thought pull request from them again.3 -
This one guy on my team had like 10 commits to a single file over a day with all kinds of wild changes.
Build is broken most of the day (not mine but whatever).
Finally, at end of day he says it is fixed.
I diff the first and last changes.
Copyright changed...wtf2 -
My boss asked for exemples of reset password process from diff apps, i showed him DevRant.
"So, what does this app do ?"
I did a mistake ._.3 -
I love #VisualStudio.
See how visual studio really makes easy to analyze difference between two version of file. 😘😘25 -
So I'm back from vacation! It's my first day back, and I'm feeling refreshed and chipper, and motivated to get a bunch of things done quickly so I can slack off a bit later. It's a great plan.
First up: I need to finish up tiny thing from my previous ticket -- I had overlooked it in the description before. (I couldn't test this feature [push notifications] locally so I left it to QA to test while I was gone.)
It amounted to changing how we pull a due date out of the DB; some merchants use X, a couple use Y. Instead of hardcoding them, it would use a setting that admins can update on the fly.
Several methods deep, the current due date gets pulled indirectly from another class, so it's non-trivial to update; I start working through it.
But wait, if we're displaying a due date that differs from the date we're actually using internally, that's legit bad. So I investigate if I need to update the internals, too.
After awhile, I start to make lunch. I ask my boss if it's display-only (best case) and... no response. More investigating.
I start to make a late lunch. A wild sickness appears! Rush to bathroom; lose two turns.
I come back and get distracted by more investigating. I start to make an early dinner... and end up making dinner for my monster instead.
Boss responds, tells me it's just for display (yay!) and that we should use <macro resource feature> instead.
I talk to Mr. Product about which macros I should add; he doesn't respond.
I go back to making lunch-turn-dinner for myself; monster comes back and he's still hungry (as he never asks for more), so I make him dinner.
I check Slack again; Mr. Product still hasn't responded. I go back to making dinner.
Most of the way through cooking, I get a notification! Product says he's talking it through with my boss, who will update me on it. Okay fine. I finish making dinner and go eat.
No response from boss; I start looking through my next ticket.
No response from boss. I ping him and ask for an update, and he says "What are you talking about?" Apparently product never talked to bossmang =/ I ask him about the resources, and he says there's no need to create any more as the one I need already exists! Yay!
So my feature went from a large, complex refactor all the way down to a -1+2 diff. That's freaking amazing, and it only took the entire day!
I run the related specs, which take forever, then commit and push.
Push rejected; pull first! Fair, I have been gone for two weeks. I pull, and git complains about my .gitignore and some local changes. fine, whatever. Except I forgot I had my .gitignore ignored (skipped worktree). Finally figure that out, clean up my tree, and merge.
Time to run the specs again! Gems are out of date. Okay, I go run `bundle install` and ... Ruby is no longer installed? Turns out one of the changes was an upgrade to Ruby 2.5.8.
Alright, I run `rvm use ruby-2.5.8` and.... rvm: command not found. What. I inspect the errors from before and... ah! Someone's brain fell out and they installed rbenv instead of the expected rvm on my mac. Fine, time to figure it out. `rbenv which ruby`; error. `rbenv install --list`; skyscraper-long list that contains bloody everything EXCEPT 2.5.8! Literally 2.5 through 2.5.7 and then 2.6.0-dev. asjdfklasdjf
Then I remember before I left people on Slack made a big deal about upgrading Ruby, so I go looking. Dummy me forgot about the search feature for a painful ten minutes. :( Search found the upgrade instructions right away, ofc. I follow them, and... each step takes freaking forever. Meanwhile my children are having a yelling duet in the immediate background, punctuated with screams and banging toys on furniture.
Eventually (seriously like twenty-five minutes later) I make it through the list. I cd into my project directory and... I get an error message and I'm not in the project directory? what. Oh, it's a zsh thing. k, I work around that, and try to run my specs. Fail.
I need to update my gems; k. `bundle install` and... twenty minutes later... all done.
I go to run my specs and... RubyMine reports I'm using 2.5.4 instead of 2.5.8? That can't be right. `ruby --version` reports 2.5.8; `rbenv version` reports 2.5.8? Fuck it, I've fought with this long enough. Restarting fixes everything, right? So I restart. when my mac comes back to life, I try again; same issue. After fighting for another ten minutes, I find a version toggle in RubyMine's settings, and update it to 2.5.8. It indexes for five minutes. ugh.
Also! After the restart, this company-installed surveillance "security" runs and lags my computer to hell. Highest spec MacBook Pro and it takes 2-5 seconds just to switch between desktops!
I run specs again. Hey look! Missing dependency: no execjs. I can't run the specs.
Fuck. This. I'll just push and let the CI run specs for me.
I just don't care anymore. It's now 8pm and I've spent the past 11 hours on a -1+2 diff!
What a great first day back! Everything is just the way I left it.rant just like always eep; 1 character left! first day back from vacation miscommunication is the norm endless problems ruby6 -
!rant
!!pride
I tried finding a gem that would give me a nice, simple diff between two hashes, and also report any missing keys between them. (In an effort to reduce the ridiculous number of update api calls sent out at work.)
I found a few gems that give way too complicated diffs, and they're all several hundred lines long. One of them even writes the diff out in freaking html with colors and everything. it's crazy. Several of the simpler ones don't even support nesting, and another only diffs strings. I found a few possibly-okay choices, but their output is crazy long, and they are none too short, either.
Also, only a few of them support missing keys (since hashes in Ruby return `nil` by default for non-defined keys), which would lead to false negatives.
So... I wrote my own.
It supports diffing anything with anything else, and recurses into anything enumerable. It also supports missing keys/indexes, mixed n-level nesting, missing branches, nil vs "nil" with obvious output, comparing mixed types, empty objects, etc. Returns a simple [a,b] diff array for simple objects, or for nested objects: a flat hash with full paths (like "[key][subkey][12][sub-subkey]") as top-level keys and the diff arrays as values. Tiny output. Took 36 lines and a little over an hour.
I'm pretty happy with myself. 😁6 -
Okay guys, this is it!
Today was my final day at my current employer. I am on vacation next week, and will return to my previous employer on January the 2nd.
So I am going back to full time C/C++ coding on Linux. My machines will, once again, all have Gentoo Linux on them, while the servers run Debian. (Or Devuan if I can help it.)
----------------------------------------------------------------
So what have I learned in my 15 months stint as a C++ Qt5 developer on Windows 10 using Visual Studio 2017?
1. VS2017 is the best ever.
Although I am a Linux guy, I have owned all Visual C++/Studio versions since Visual C++ 6 (1999) - if only to use for cross-platform projects in a Windows VM.
2. I love Qt5, even on Windows!
And QtDesigner is a far better tool than I thought. On Linux I rarely had to design GUIs, so I was happily surprised.
3. GUI apps are always inferior to CLI.
Whenever a collegue of mine and me had worked on the same parts in the same libraries, and hit the inevitable merge conflict resolving session, we played a game: Who would push first? Him, with TortoiseGit and BeyondCompare? Or me, with MinTTY and kdiff3?
Surprise! I always won! 😁
4. Only shortly into Application Development for Windows with Visual Studio, I started to miss the fun it is to code on Linux for Linux.
No matter how much I like VS2017, I really miss Code::Blocks!
5. Big software suites (2,792 files) are interesting, but I prefer libraries and frameworks to work on.
----------------------------------------------------------------
For future reference, I'll answer a possible question I may have in the future about Windows 10: What did I use to mod/pimp it?
1. 7+ Taskbar Tweaker
https://rammichael.com/7-taskbar-tw...
2. AeroGlass
http://www.glass8.eu/
3. Classic Start (Now: Open-Shell-Menu)
https://github.com/Open-Shell/...
4. f.lux
https://justgetflux.com/
5. ImDisk
https://sourceforge.net/projects/...
6. Kate
Enhanced text editor I like a lot more than notepad++. Aaaand it has a "vim-mode". 👍
https://kate-editor.org/
7. kdiff3
Three way diff viewer, that can resolve most merge conflicts on its own. Its keyboard shortcuts (ctrl-1|2|3 ; ctrl-PgDn) let you fly through your files.
http://kdiff3.sourceforge.net/
8. Link Shell Extensions
Support hard links, symbolic links, junctions and much more right from the explorer via right-click-menu.
http://schinagl.priv.at/nt/...
9. Rainmeter
Neither as beautiful as Conky, nor as easy to configure or flexible. But it does its job.
https://www.rainmeter.net/
10 WinAeroTweaker
https://winaero.com/comment.php/...
Of course this wasn't everything. I also pimped Visual Studio quite heavily. Sam question from my future self: What did I do?
1 AStyle Extension
https://marketplace.visualstudio.com/...
2 Better Comments
Simple patche to make different comment styles look different. Like obsolete ones being showed striked through, or important ones in bold red and such stuff.
https://marketplace.visualstudio.com/...
3 CodeMaid
Open Source AddOn to clean up source code. Supports C#, C++, F#, VB, PHP, PowerShell, R, JSON, XAML, XML, ASP, HTML, CSS, LESS, SCSS, JavaScript and TypeScript.
http://www.codemaid.net/
4 Atomineer Pro Documentation
Alright, it is commercial. But there is not another tool that can keep doxygen style comments updated. Without this, you have to do it by hand.
https://www.atomineerutils.com/
5 Highlight all occurrences of selected word++
Select a word, and all similar get highlighted. VS could do this on its own, but is restricted to keywords.
https://marketplace.visualstudio.com/...
6 Hot Commands for Visual Studio
https://marketplace.visualstudio.com/...
7 Viasfora
This ingenious invention colorizes brackets (aka "Rainbow brackets") and makes their inner space visible on demand. Very useful if you have to deal with complex flows.
https://viasfora.com/
8 VSColorOutput
Come on! 2018 and Visual Studio still outputs monochromatically?
http://mike-ward.net/vscoloroutput/
That's it, folks.
----------------------------------------------------------------
No matter how much fun it will be to do full time Linux C/C++ coding, and reverse engineering of WORM file systems and proprietary containers and databases, the thing I am most looking forward to is quite mundane: I can do what the fuck I want!
Being stuck in a project? No problem, any of my own projects is just a 'git clone' away. (Or fetch/pull more likely... 😜)
Here I am leaving a place where gitlab.com, github.com and sourceforge.net are blocked.
But I will also miss my collegues here. I know it.
Well, part of the game I guess?7 -
a tale of daily frustration:
git fetch
*yup I'm up-to-date ...*
git add -p .
*hack in beautiful patch ...*
git status -bs
*correct branch, didn't forget any files ...*
git diff --cached
*yep, that is what I mean to commit ...*
git commit -m"[TKT-NUM] Meaningful commit message"
git log -p -1
*double-checking ... looks good ...*
git push remote tkt-num-etc
*for a brief moment feel accomplished ...*
*notice typo in commit message ...*
I don't have a funny image or punchline to sum this post up. But know that if you recognise this feeling, then I am your brother in git.6 -
Warning: Long rant ahead!
So we built an amazing system for managing swarms of drones, and we have flown hundreds of hours, testing, etc.
Comes a client and says, that he wants to buy our system, but he wants to integrate it in a bigger system that is supposed to orchestrate many small systems.
Sounds like a deal.
So they send me on a week course (see previous rant: https://devrant.com/rants/2049071/...) to learn how to integrate our system in theirs.
I was sure that they have some API or something and it should be a breeze. but apparently they give us an SDK that includes all their files, and we have to build and run their entire system, and then build our own API inside of it!
And the reason we needed a week-long course, was to know all the paths where the XML configuration files exist!
So for the last month, I am hacking away inside this huge program, navigating thousands of files in a language I don't know, in order to build an API for their system, so that I can use it on our side.
Yesterday they informed us that a new version is available.
And sure enough, waiting in my inbox this morning was a link to download a new SDK.
No Changelog, No Instructions, Just a zip file with over 25,000 files.
So I phone my contact in their company to ask how exactly I am supposed to update their files, and his answer was: diff them!
WHAT! 25,000 files, half of them built by the c++ compiler, tens of configuration files scattered in different places, linking all the new libraries from scratch, are they crazy or what?
And then he tells me that they are working for 15 years this way. That's why everyone hates them I guess.
going to have a long day...
P.S. many more rants to come from this integration.4 -
Can anyone make a simplistic version control like git for microsoft word? I just want an easy check in, check out, and seeing the diff. Goddamn some of these tools got a lot of steps19
-
Hey Designer/Developers, I got a question for you. Yeah, you 👇🏽
When working on a project codebase that is expected to grow and evolve heavily. How do you usually split up your CSS (SASS, LESS etc) in a good way to take into account all the different device sizes?
I am not asking how it is done but more about the design of the code. This would be for a production codebase to be released.
Do you use large blocks broken down by media...
(Media width) {
~site code
}
(Other media) {
~same site code with diff sizes
}
Or do you do individual media queries inside css classes...
.className {
(Media size) {
}
(Other media) {
}
}
Or a mixture of both?
If it is a mixture of both then how do you decide which way to go about structuring the code.
I have been endeavouring to greatly improve my CSS and have done so. But this question has been bugging me. Both sides seem to be a bit sloppy and my programmer side is fighting the repeatitipve code.
Note: all code examples are gibberish and only intended for visualization.17 -
Colleague: Hey could you review this diff?
Me: *opens Bitbucket*
Bitbucket: "Upgrade to Symfony 5", 19 files added, 732 modified, 14 removed
Me, 3 mouse scrolls and 20 seconds later: ✅3 -
Boss: some consultants worked on this feature extending some legacy code
Boss: it's 90% done
Boss: they used FTP. It uses iframes and we fired them when they couldn't get the frontend modules working in sync with the backend.
Me: git checkout -b herewegoagain
git diff-tree --no-commit-id --name-only -r 666w3wl4d
*copy output list of files to sublime text 3; select all lines; add to each:
gitk --follow [filename] > src/.notes/herewegoagain/[filename].diff
*examines....
Me: It's -10% done. you'll know I'm almost done when I enter the fugue state. You'll find me at this address. Give me this USB stick and a 4 pack of redbull and I'll do the merge.6 -
Maybe in special dedication to @kiki.
I cut the unit tests down in LOC size by roughly 50 - 60 % in most projects.
It's really easy once one sees unit tests not as a dunking pile of copy pasta wild west, but rather as a code base that needs architecture and design.
Some extensions, some annotations, some good old helper classes.
Pooooof.
Why I did this? ...
Because it's fucking annoying when you read a PR with tests and need a fucking diff tool to spot the difference between two tests cause they're 80 % the same.
Yeah. Thx for giving me brain cramps, motherducker.
I'm not an expert in unit tests, but if all test codebases look like the "usual stuff" in our projects...
It's no wonder bugs exist...10 -
Git: Before you pull you need to commit your changes
*Doesn't even run a git diff to see what changes git was talking about.*
git checkout .
git clean -i
git pull2 -
fck you visual studio!!! seriously what is wrong with you?!?
~me peacfully writing some code ~
ok let's see what we did
vs: I can't compile that. The key whateverKey in line 15 is not defined.
me: ok let's investigate...
nowhere in line 15 use whateverKey.... ok....
wait I didn't change that file at all.
~me clicking rebuild solution~
vs: can't build that because of whateverKey in line 15.
me : WTF?!?
checking git diff -> file not changed
me okkkkkkk......
closing visual studio and reopening solution.
Build succeeded.
What the actuall hell?!?
I'm spending way too much time trying to get that shity peace of software to do what it is supposed to do!6 -
I love how different figures in tech got really different reputations.
Take Elon Musk and Mark Zuckerberg. We all love Elon.
What did they do different? What did they do wrong?6 -
What is it with people just blindly fucking copy pasting from a different project, seeing it work and then submitting it for review.
You copy 2 lines, one of which fixes the thing, WHY KEEP THE OTHER USELESS IRRELEVANT PIECE OF FUCKING SHIT IN THE FUCKING CODE WHY BOTHER WITH KEEPING IT IN IT'S MORE TECH DEBT BECAUSE NOBODY WILL KNOW WHY IT'S THERE
WHY DO I CONTINOUSLY HAVE TO POINT THIS OUT IT'S SO FICKONG TIRING TO CONSTANTLY HAVE TO BE THE ANNOYING REVIEWER WITH +20 COMMENTS ON SMALL PRS IM SO FUCKING TIRED OF BEING 'THAT GUY'
In my language it's called being 'slordig'. Whenever I submit sometning for review I always go over the diff to see is I missed anything that is no longer required and remove it WHY DONT THEY DO THAT TOO
And then their PR stays open for 2 weeks like they forgot about it and during standup they say 'its in review' like I havent already looked at your piece of shit code
FUCK2 -
WTH...
While styling some frontend stuff with LESS, I experienced that on one page template the <header> was not displaying the given line-height eventhough the whole fscking code was 1:1 identical with the other template in which everything was fine. I checked EVERYTHING... caching, URL, source, classes, open / wrong tags, HEAD, ... I even did a diff compare. NO FSCKING DIFFERENCE!
After one hour of pulling out hair I suddenly saw that in the faulty template file 2 lines were missing:
<!DOCTYPE html>
<html lang="devRantLang">
WHOEVER DID THIS: YOU ARE FSCKING STUPID!!! (it was me...)7 -
Dumbass... I tell him what the problem is and show him the evidence...
But after a week they investigating a diff thing or basically have no idea wtf his looking at....
I should just stop checking work emails while on vacation... Just let idiots screw themselves and see how badly they wander off course and where they end up -
Had a guy put in a pull request with an empty file diff. He comes by two weeks later and asks when am I going to have time to review it.
-
I think the reason why git beginners have a hard time with it is because the api is a bit untuitive.
For example: if you want to "unstage" staged changes, you run git reset, and if you want to "delete" those changes from your working copy, you git checkout those files.
But then, you find out that you can do all of that if you git add . and git reset --hard.
So you're like "huh..."
And then you discover that if you end the resethard with a branch name/commit id then you also make current branch point to the commit or that branch/commit (respectively).
So you're like "huh..."
And also if you add a commit id or branch name to git checkout, you change the current branch to specified/enter detached state with HEAD pointing to that commit (respectively).
Oh and you don't use git branch to create branches, you use git checkout -b because it's a lot shorter.
So here's a rundown: git reset mutates things related to files, but also mutates things related to branches.
git checkout also mutates things related to files and mutates things related to branches too (in a diff way). Also, creates new branches.
I don't think this is intuitive. We users use the same commands for different purposes with just a different flag.
Commands shouldn't mutate different types of things. But don't composite commands (as in, "smart" commands that mutate different things) shoudln't be a flag in an existing command, it should be a single new command of its own.
Maybe if I reread the internals of git now, I'll be able to disgest the dozens of technical terms they throw at you (they are many). And in my mind, the api will cognitively fit to the explanations.
Here's another one that feels weird too.
If you want to make your changes start on top of someone else's commit, you do git rebase.
But git rebase -i can be used for that, and also to delete, modify changes or message of, reorder or combine previous commits of the current branch.
Maybe the reason why several things we do overlap with the same commands is because they internally do similar things, and while not separating those commands might make it less intuitive, it makes them more sensible? i dunno...
disclaimer: I'm not setting this opinion in stone though, and am aware that git was created by one of the most infuential programmers.6 -
Elasticsearch, from the bottom of my heart...
How can one ecosystem be so batshit crazy inconsistent?
Seemingly every agent does the same (e.g. filebeat vs journalbeat vs packetbeat)… yet there are subtle changes in configuration everywhere.
Plus YML. The most shitty markup language one can use and the cockslubbing durps used it fucking everywhere.
Makes fun to have complex stuff and requiring a python Jinja to JSON to YML converter to be able to write the complex stuff without having the fucking migraine to count like a stupid 4 year old whitespace with both hands...
To make it even more absurd: the ingest pipelines which contain a lot of regular expressions / grok and are thus very prone to quoting issues... Yes. Let's do this in YML too.
If you need to add an fucking manual section how to debug YML errors you should have realized what a fucking stupid idea it was, morons.
Now I have the joy of having a python script regex quoting the shit for a Jinja template which then generates JSON which then generates YML.
Why the JSON part?
Yeah... Because ECS and changes in the upstream YML files / GitHub.
To be able to run diffs in a sane way because in YML distinguishing thing is pretty much impossible, so JSON as an intermediary format solely for the purpose of converting upstream YML to JSON to diff it against modified JSON ingest pipelines downstream.
I fucking hate elasticsearch8 -
Hotel wifi: Weak signal of a slow wifi that works once per 10 minutes
*goes to diff hotel*
New hotel wifi: Weak but stable signal that is fast and works all the time; admin:admin1 -
If Java versions can coexist on a system
If all java versions have their own packages on the AUR
If you can change envvars in a launch script and be sure that all processes of the application will persist your settings
Then why THE FUCK do package maintainers keep announcing to change the default java version to install their package, rather than explicitly doing that by themselves? Fuck off, do you really think yours is the only package that needs a specific Java version? Do you think each and every user will write their own init script, or edit the PKGBUILD to include the new version as an envvar in the desktop file? This is why Arch has a bad name, and they're fucking right. If you don't have the time to put a single motherfucking diff in the motherfucking pkgbuild to specify the java version in the desktop file, then don't fucking maintain the package. I know there are too few maintainers, but pretending to maintain a package while doing fuckall is much worse than leaving it unmaintained on the AUR so the first person who has time can pick it up.1 -
My biggest problem with Visual Studio Code is that every fucking piece of shit dev thinks it's their duty to introduce it to me. STOP. Just stop this shit, alright? Wanna use vscode? Fine, just don't tell me it's the best tool and I MUST use it instead of the tools I'm used to. I'm tired of this bullshit.
Every new project, every new team. Starting from js/java/.net monke and ending with PMs, I must hear this bullshit about god blessed IDE that I must use, because "why you need intellij/webstorm/rider? just install vscode and some plugins. we all use it in our project and it's ok".
FUCK YOU! Refactoring is not just renaming variables and extracting blocks of code into functions. If you want terminal integrated into your text editor with highlighting and LSP support, so be it. I want an IDE with rich refactoring tools, code analysis and good completion, database viewing/modeling support, good build tools support, good UI for git and git-diff, good test and code coverage support. I don't want your semi-IDE, bloated with hundreds of bugged third-party plugins, which I must spend a week on to configure and merry with each other before using.
JUST STOP this crap and let people use the tools they are proficient/comfortable/productive with.18 -
So, today I wanted to program a bit and, after reading the last chapter, I want to see what I able to do.
I run my last Linux distro, I open sublime and I start typing code. I finish, I build. 0 warning, 0 errors. Nice! I execute the code: error.
I watch and I struggle on the code for hours, I search on Google, I search on StackOverflow, but after 1 hour I notice I'm looking for a needle in a haystack. So I search instead for a way to produce a better error. I found it, I'm very happy. Let's try what the error actually is:
Error: success
Ok....
Ok...... Well, maybe.... Uhm......
Ok, I won't give up. I search for a tutorial. Found.
The code is almost the mine, it's actually a usual snippet, nothing new. I compare my code with the code in the example/tutorial.
First line, is the same.
First 10 lines, are the same.
First 30 lines, are the same.
I build and execute the example: it works.
I build and execute my code: still doesn't work.
I won't give up, I said it. I won't give up.
I wonder if there's a tool like git diff, so I can see what the differences are, maybe I've no good eyes.
I search, first Google result, "diff"
diff myCode.c example.c
"the files are not identical"
...thank you
I search for a better command
diff -y myCode.c example.c
"the files are not identical"
I search for a still better command
Found. StackOverflow stroke again.
sdiff myCode.c example.c
"the files are not identical"
.....
....
.....
I gave up.
Ps. I've 10 years of experience in programming4 -
My worst code review involves line endings. In one of our products we use the facade pattern, and one of the facades is about 5000 loc.
Well, a dude in our team messed up with line endings, so our diff tool showed that 5000 lines have changed. A newb I was at that time, I didn't know any other diff tool, so I went through all the lines manually only to see that 2 lines effectively have changed.. and the newb I was, didn't thought about rejecting the change immediately! We then had somehow to revert that commit, but messed up our central repo (was still with CVS). In the end we had to restore the daily backup for the repo because we couldn't manage it to do it right.
Never ever had such a disastrous code review again. -
I am strong technically, resourceful, with good analytical thinking, but I suck at comms. I lack patience and I struggle with communicating in a politcorrect business-friendly language when reaching out to other technical teams. I feel and behave as if they were all local folks, as if in a walking distance from my desk, when irl they [the client] may as well be on a diff continent
How can I improve? Anyone else had a similar problem? How did you overcome it?
Is this nuance going to be a problem in a career path past the senior chair?
What do you reckon?4 -
Yes, php, it makes total sense that `array_diff` compares the string representation of the elements.1
-
Just completed learning HTML from Jon duckett book! Feel so good. Wanted to learn coding so long. And I finally start. Starting CSS very soon. It's my first rant !! Reading rant almost more then 4 months from diff. Account. Just a newbie here. Saying everyone Hi😊 Doing #100daysofcoding !1
-
This is so annoying, I had 9 diff. jobs the past 2 years and this is my 10th and if this doesn't change I might reconsider my options again.
I came to work at a company that pays me like a Junior and treats me as an intern. My 20yo "boss" who acts as a project owner/lead dev doesn't want to learn anything new and sees any improvement as a waste of money. The problem is he thinks hes a great programmer but he doesn't know shit. Im mainly working on the Laravel installation because "I claimed I know Laravel". And its absolute garbage. They haven't used a single Laravel features besides routes and everything else is vanilla PHP. They write for loops that loop through $_REQUEST to remove a single character. Write 100 deep nested ifs and they abuse Elasticsearch to the point ES crashes because the program is using 1000 deep multidimensional arrays. Its only a webshop...
Everytime I try to make a suggestion like making the master branch protected, doing code reviews etc etc I get shut down because they are autistic and don't want anything to change.9 -
Ever heard of this custom ROM called Unleash-OS ?
Well if you've not, you're doing really well in your life. If you're happy, you can scroll away right now.
And in case you want to test strength of your happiness.
Just see here :
https://github.com/Unleash-OS/...
If you still are happy, you're pretty damn happy person. If you're not well I'm sorry, it'll just take you 10 minutes to recover.
The reason why I ranted about this is that I want everyone to be sane and NEVER do some shit like this.
Peace !1 -
In This Rant: A mildly satisfying piece of mind story.
Using code to prove yourself right is a hell of a drug.
A few weeks ago I whipped up a tiny program that downloads configs from hardware we manage. Since the vendor's API documentation is hidden behind a pay wall, my method of extraction is different. It results in bigger files, but testing showed it to still be valid.
Enter today. Interns at work downloaded a config to load onto a spare machine and it won't work.
"TheCapeGreek, your configs don't work"
I was confused since I tested the files when I built it and it worked. I am also currently fleshing out that download utility's features so the fear that I've been wasting the past 2 weeks on improvements is looming.
Last 15 minutes of the day and nothing else to do so I figured I might as well whip up a string comparer. The smaller file's content is scattered in the big file so a direct diff won't work.
Code it all, quick hardcoded proof of concept code, bit it got the job done. I was right, my bigger file is still correct!
Turns out the issue was with the machine they were configuring. They found this out before I finished my test code, so I'm off the hook already, but it was good to have piece of mind haha!1 -
Wow or wtf to these banks API. was integrating an API for a service which accept JSON input.
Okay fair enough, that would be fine
Spent an hour writing code(purescript) most of time spent was on writing Types based on the API doc. after that okay let me test the API it failed.
I was what happened? So tested the API from postman with the payload from the doc, it worked. What how?
used a JSON diff to compare the payload from postman and the log. Looked same to me after spending few hours checking what is wrong with it .trying changing value to pasting the body of the log request in postman and trying everything failed.
Later went to the original working payload provided by them and changing the order. It started throwing error. I was like wait what?
It must be only on there UAT. created a payload with production creds and hoping to our production server (they have IP whitelist) ran the curl with proper payload as expected it worked. Later for same payload changed the order or one key and tried it failed.
Just why????
I don't want to create a JSON with keys on specific order. Also it's not even sorted order.4 -
My worst legacy code experience:
>10k lines of switch case statement with "some" fall through.
Even fall through for 4 or 5 cases.
This monster was copy pasted and modified over years (Order of the case statements and another fall throughs).
So you can't diff this piece of shit for refactorings.
Luckily I leave that company. -
A house.. or lego star destroyer..😝😆
Joke aside, I'd rewrite current project from scratch to get rid of all the automation and IE dependancies and make it cross browser and all the dead code...and all excess ORMs and especially EFCF..and also make support for db diff than oracle..and no need for ora client installation..
Yeah, I'm a work junky, I have no projects of my own.. one kid is demanding enough of my time.. 😉3 -
Once I sent an email to a coleague asking what is the diff between @Resource and @Autowired annotations.
A simple google qry would have handed me the answer right away..1 -
!RANT
Bet the diff between a beginner developer and an intermediate developer is where to get code snippets either from old codebases or remote resources. -
Below is a transcript from work Slack today. Only the names and some code are changed. It ended up causing a bit of drama. DevRanters, what do you take from this?
---
Delivery Lead:
Hey Gang. What's the blocker for FEATURE-123?
Dev1:
FEATURE-122 crashed on iOS app when viewing Feature Introduction page.
Teach Lead:
I've talked about this with Dev1 on a side channel.
And diagnosed the stack trace.
It looks like there is/was some bad handling of a List in the Feature Introduction view logic.
But this is confined to changes that Dev2 is still working on.
(It's not present in master)
Dev2, what's your current position on this?
Dev2:
I have tested at my end with Dev1 but it seems to be working fine
Tech Lead:
There is a race condition related to the use of someList.first()
My guess is that theres a Flow of those lists defined, with an initial value of emptyList
And that on your machine, that Flow is updating with a new value quickly enough that it doesn't matter.
But on Dev1's, for whatever reason, it doesn't get there in time, hits the empty list and falls over.
The logic that's performing the first() needs to gracefully handle empty lists as well.
Dev2:
Where is that logic called?
Tech Lead:
Here's the stack trace Dev1 provided in our conversation earlier:
Caused by: kotlin.NoSuchElementException: List is empty.
...
at 3 iosApp 0x00000000 kfun:kotlin.NoSuchElementException#<init>(kotlin.String?){} + 00
at 4 iosApp 0x0000000 kfun:kotlin.collections#first@kotlin.collections.List<0:0>(){0§<kotlin.Any?>}0:0 + 000
...
at 9 iosApp 0x0000000 kfun:kotlin.coroutines.native.internal.BaseContinuationImpl#resumeWith(kotlin.Result<kotlin.Any?>){} + 0000
This line:
kfun:kotlin.collections#first@kotlin.collections.List<0:0>()
...says that it's first() being called on an empty list.
Dev1:
FYI: Dev3/Dev4/myself are seeing the same issue with the same stack-trace above.
Tech Lead:
So Dev2, have you introduced such a call?
Because I checked master branch and there isn't one, in that version of the file.
Ok, I'll check your working branch Dev2
...
Yes you have here:
var processed1 = someList.first()
var processed2 = someList.first()
...
Lines 123, 124.
Solution looks really straightforward guys.
Dev2:
Okay, I will fix that and push the change
Tech Lead:
Check if someList is empty and allow for generating / handling null processedValues in the view.
Now; I'm going to be straight with you here.
This issue has been discussed over several hours today.
I expect that either one of you could have gone through the process I did in the last 10 minutes above, and resolved it in the same way :point_up:
Dev2:
I went on a break and it's not reproducible on my machine
Tech Lead:
I didn't reproduce it on mine either.
Dev1:
Dev2 and myself are now on sharing screen to sort this issue out. Hope to update back later.
Tech Lead:
<Screen shot of diff with changed code>
:point_up: That change should do it.
Dev2:
Already have pushed the change.
Tech Lead:
...just seen it, is good - same approach :ok_hand:
Dev1 please let us know when tested on your machine.
Dev1:
That does it. It fixes the issues. Thank you, Dev2. I will pick it off from here.
Tech Lead:
Glad to hear it guys.
Dev1:
I have to say this that it is not because we are not working on the issue - Dev2 and myself (together with Dev3/Dev4) have been on this issue all this morning. It just difficult to connect the dot when it wasn't reproducable on Dev2's machine. I brought the issue up because I wanted to switch to working on other tickets while waiting for this to resolve. Still thank you largely for Dev2's work and your keen eyes that spot and resolve the issue quickly.
Tech Lead:
Noted Dev1.
I think the take-away has to be to read the stack-trace carefully... don't worry - we've all been guilty of not reading the error in full, at some point.
The stack trace said that the 'first' element is being referenced from an empty list - that's just logically impossible, right?
Looking for that call to first, we saw it wasn't in the code before, and is after (two of them, in fact).
So then we ask ourselves, how can we deal with an empty list - and then solution almost presents itself.
It didn't really take reproduction of the error to resolve.
Maybe working with a new tech stack creates an anxiety that every issue faced will have a complex solution related to that stack; but I think you'll agree, this particular issue really just required a deep breath and your trusty 'debugging skills 101'... don't lose them! :smiling_face:4 -
I love when devs bitch about the size of PRs on a very standard sized one. They're all related changes that can't be broken up. Do you want the app to be broken between PRs? He spent more time bitching about the size of the diff and telling me how he does it better instead of just reviewing the code. A tip or an ask is one thing, this was a wall of text.
Oh and he still didn't approve the PR, which I know he looked at, and didn't leave any blocking comments.4 -
Converting server time to any given local timezone is a pain in the ass.. at least in JS.
Here's what I've got:
convertNowToTimezone = (localOffset) => {
let d = new Date();
let millis = d.getTime() + (d.getTimezoneOffset() * 60000); //convert server local time to UTC millisec
d.setTime(millis - (localOffset * 60000)); //convert UTC millisec to required local time
return d;
}
where I pass localOffset as -330 (IST offset).
Works in chrome console but gives a diff of 4min in the server side nodejs I'm running it in..
🤬🤬😡😡😡😡😡9 -
Needed money for my company, not enough clients to support business on SaaS alone. Took on a 5k / month job building a platform that competes with my SaaS (more niche, less generic). Also sign up new client who that company's owner is part owner onto my current SaaS. Win / Win?
I do a lot of custom work to my platform to fulfill their needs, which is why I ran out of time for the 5k / mo project. I did these customization for free. Losing money to keep client, but also improving my system.
Work gets busy, I need to drop the 5k project. Client is upset I am working more on his other company (he is not majority owner). I return 1 month of funds to the owner and say I cannot continue.
Owner threatens to make other company that he is part owner stop working with my software if I do not complete project. Blacklisting...great. I agree to work with an overseas developer to do it and PM it for 3 months at least. Making nearly nothing from it (now 1k / month for PM), working nights to deal with India, losing sleep...
Other company suddenly folds due to conflict of egos with that SAME owner. Users drop from 16 to 1. I drop the project, no more strong arming me. Everything is a loss, all effort and money lost for nothing. Bad bet..however...
Owner becomes 100% owner of the other company, and of the software company. I transition him to PM his own project, he still uses my software because It doesn't, nor will it, ever do what the one he is building does. Also, partners from previous company break off and use my software again. New Client. #profit.
But holy hell was it stressful in the interim. People's business tactics are disgusting. Stay calm, play it neutral. Win. Sometimes you have to do what you don't want to do in order to succeed...at least for a little bit.
I was so scared that how he screwed his partners he would screw me over as well if I built one of the modules I have planned for my System, but haven't done yet.
If I did it for him first and then built my own (totally diff codebase) I really didn't want to run into any legal issues considering the schematics he has now are mine, but I didn't finish that part of the system for him. He is obivously highly competitive. Even though he wanted me to, and still does, want me to run his company for him.
Who knows, maybe in the future. To be CTO / COO of two SaaS CRM's in the same space may make sense. But I will never sell my software to him or partner with him. Too much drama. Avoid the drama. Be careful out there fellas.
If you are a creator, people will take advantage of you in every way imaginable. Read the fine print, read the people, document everything. Don't put yourself at risk. -
! War
I hate tabs to space, yep i hate it, nobody could ever give me a good reason to use spaces over tabs
(yes i want to have differend tab sizes on differend Plattforms/environments, my buddys all use 4 or even 6 as tab size, i only use 2. With tabs can everbody got his/her own size without reformating the whole code and driving diff crazy @all lines changed!!!111onehundredeleven)12 -
which *git* diff algorithm is your default and why?
## default (myers)
The basic greedy diff algorithm. Currently, this is the default. if you don't know whart you are using, this is it (and it sucks)
## minimal
Spend extra time to make sure the smallest possible diff is produced.
##patience
Use "patience diff" algorithm when generating patches.
## histogram
This algorithm extends the patience algorithm to "support low-occurrence common elements".4 -
Remember I wanted to do a small web app but found out there were already 5 or so which did the same thing and got discouraged and you lot cheered me to do it anyway?
It's a web app to get a diff from two texts, with the ability to save the diff and get a shortlink to it :)
Enjoy: https://finddiff.com1 -
Gah I'm so mad at openCV right now. Is so stupid. Why the heck does it's kalman filter implementation accept 'float' as an acceptable type but not 'np.float32' gah gah gah it's so dumb spent half my day on that gah thank God for git diff it saved me cause it worked before and now gahhhhh. Anyway.
-
Can someone get an excerpt from the SO user db and diff it against the DevRant user db and compile a do-not-hire list of the ones that are only on SO?
And yes, I was recently triggered by a SO elitist.
This also assumes all the nice SO members are members of DevRant, which I think is fairly accurate.2 -
I'm shitting there hammering out some code butchering some real problems when I suddenly realise I'm surrounded. I look around and yes it's the bloody committee.
The committee is what I call the rest of the department and it is dominated by the old guard which comprises of the programmers that have been around for longer.
None of the old guard can program particularly well but because they had been around the longest they'd all grown senior. The committee had free reign but anyone else doing anything differently has to get approval from the committee.
The only way to code otherwise was to copy and paste existing code then to primarily rename things. If anyone did anything that hadn't been seen before then it would have to be approved by the committee. Individual action was not permitted unless you were old guard.
I swept my headphones away expecting it to be something unimportant. It was.
First things first they announce. We're going to add extraneous commas to the last element of all possible lists separated by comma including parameters or so they say. Ask but why so I do.
Because the language now supports it. They added support for it so it must be the right way someone proclaimed. Does it? I didn't realise we were waiting for it. Why do we want it though?
Didn't you hear? It's all over the blogosphere. It massively improves merge requests. But how I ask?
Five minutes later I grow tired of the chin stroking, elbow harnessing, slanted gazes into the yonder and occasionally hearing maybe its because and ask if they mean when you for example add an element the last element registers as changed from adding a comma. Turns out that's all it is.
How often do we see that tiny distraction and isn't it pointless to make the code ugly just for a tiny transient reduction in diff noise I ask. Everyone's stumped. This went on and on and got worse and worse. But it makes moving things around easy half of them say in unison like the bunch of slobs that they are. I mean really. It doesn't make expanding and contracting statements from multiline to single line easy and it's such a stupid thing. Is that all they do all day? Move multi-line method parameters up and down all day? If their coding conventions weren't totally whack they wouldn't have so many multiline method prototypes with stupid amounts of parameters with stupidly long types and names. They all use the same smart IDE which can also surely handle fixing the last comma and why is that even a concern given all the other outrageously verbose and excessive conventions for readability?
But you know what, who cares, fine, whatever. Lets put commas all over the shop and then we can all go to the pub and woo the ladies with how cool and trendy we are up to date with all the latest trends and fashions then we go home with ten babes hanging off each arm and get so laid we have to take a sick day the following to go to the STD clinic. Make way for we are conformists.
But then someone had to do it. They had to bring up PSR. Yes, another braindead committee that produces stupid decisions. Should brackets be same line or next line, I know, lets do both they decided. Now we have to do PSR and aren't allowed to use sensible conventions.
But why, I ask after explaining it's actually quite useful as a set of documents we can plagiarise as a starting point but then modify but no, we have to do exactly what PSR says. We're all too stupid apparently you see. Apparently we're not on their level. We're mere mortals. The reason or so I'm told, is so that anyone can come in and is they know PSR coding styles be able to read and write the code. That's not how it works. If you can't adjust to a different style, a more consistent style, that's not massively bizarre or atypical but rather with only minor differences from standard styles, you're useless. That's not even an argument, it's a confession that you've got a lump of coal where your brain's supposed to be.
Through all of this I don't really care because I long ago just made my own code generators or transpilers that work two ways and switch things between my shit and their shit but share my wisdom anyway because I'm a greedy scumbag like that.
Where the shit really hit the fan is that I pointed out that PSR style guide doesn't answer all questions nor covers all cases so what do we do then. If it's not in PSR? Then we're fucked.4 -
What is wrong with Stackoverflow mods and so called seasoned users? Why is everyone in such a rush to close questions and point you to other questions which has no relevance.
Once they do this, is just over. Explaining why they are wrong makes no diff. And you can't just repost. The question is just dead.
Genuinely think they should just burn in hell. Sick a holes. If you're not interested in answering or helping at least stay out of people's business.12 -
Sophomore here. For a long time this has been bugging me. I'm very skeptical about what I'm learning and what I plan to learn. Just doubting myself and feeling like a loser. So today i wanna ask, what was the road you took to be where you are now? I wanna know details
Did u exceed ur expectations and do u think if u knew what u know now, u cud've done a lot better and taken a diff route?
I'm asking this cuz i wanna set a baseline of skills to attain by the time i graduate. Been researching and the amount of things u can learn is very intimidating to me11 -
Difference between 2023-01-01 00:00:00 and 2023-12-31 23:59:59 is 11 months, 29 days, 23 hours, 59 minutes, 59 seconds ; so almost a year (by one second)
Difference between 2023-01-01 00:00:00 and 2023-01-31 23:59:59 is the same, almost a month by 1 second.
Same for february (even with 28 being the last day).
But then, 2023-03-01 00:00:00 and 2023-03-31 23:59:59 gives me :
1 month, 2 days, 23 hours, 59 minutes, 59 seconds.
WHY, are there fucking 34 days in March ? Is this a bug ? Is it confused with February being the previous month ?
Why would PHP do this to me ?
Why the hell is it always so painful to work with dates, it's not even like I'm stretching the standard library or using raw timestamps to hack things together
I used the diff method of PHP 7.4 DateTime, is someone wants to try it24 -
That feel when you retire 152 files worth of dead code...
The diff was so big, it crashed our review tool! -
Coolest project was an order and billing solution for restaurants on Palm handhelds, written in C.
The cool thing was to completely develop the Bluetooth stack for communicating with printers for orders and bills.
This was the project to really teach me the diff between & and *.
Must have been around 2003, but I bet it's still running. -
Does anyone knows a Syncing / Self Hosted Cloud Solution that has native Integration for Windows and Ubuntu?
I want some shared storage between my Laptop and my PC. Save a project on one side, grab the laptop goes to a friend and work there with the data, without uploading / downloading the files manually or using some web interface for that.
I have also a root server with stroage and internet. So if it happens automagicly in background it would be fine.
Is there a good solution out there? Or some ideas / frameworks to programm it by myself?
Diff and merges are not needed. I never will work on both systems at the same time.6 -
A command-line animation command.
Input frames and an expression
It will be able to reorder frames, play video/frames/music in the background, smooth transitions, diff and patch frames and render into a video
It will be written in Go. No idea what to call it.
What do you think?8 -
1. Find a function: getDayDiff(d1, d2)
2. d1 and d2 are momentjs dates.
3. See that function performs complex ancient math rituals and then returns an integer
4. Try to rewrite function, return d2.diff(d1, 'days')
5. Should be OK right? Run tests
6. Whole module melts down. WTF?!
Turns out the math performed returned the difference + 1 because it included the current day which moment's diff() function does not (out of the box).
Processes that depended on this function then uses the result like this:
const diff = getDayDiff(d1, d2)
if (diff-1 == should_match) { /* more fun logic */ }
$ git checkout .
$ run-shutdown-script-because-fuck-you2 -
Shows perfect results.
PM: Nice, integrate that into the latest version.
Shows bad results.
PM: Your integration must be wrong.
Show him the file diff, no difference in my implementation.
It's funny how the exact same feature goes to shit immediately after they push all these untested changes. -
I HATE WINDOWS' WINDOW MANAGEMENT. I have two monitors and nothing can be maximized. Windows' spaces are terrible as well.
I am building in the back end in VS Code.
I have three terminals open because I need them to run multiple parts of the app locally.
I have postman open to try requests.
I have firefox for the orm system's documentation.
I have my database tool running as well.
I have an ERD diagram floating in a window.
I have another VS Code window showing a diff of my JSON compared to the version I'm replacing.
Also all of my team communication tools.
I have never hated shuffling windows around so much. Would it kill us to use some command line tools for http instead of Postman? Could we please get a decent shell in windows? Could we get some simple ways to switch between virtual desktops? Click click click. I can't automate clicking. Why do we use the most clicky tools we can find?17 -
Does the 99 trick work still when it's like $1499.99 vs $1500...
Do ppl still easily most the $100 diff?13 -
If you change all tabs to four spaces, no one will see your actual trashy changes in the line by line diff.
-
my git diff too big such that gitlab doesn't display it be default
oof
not a good luck when putting your changes out there1 -
That moment when you settle for Consolas, after trying 13 diff mono fonts, because you need ClearType so that Office apps don't suck...bye bye Operator Mono...Incosolata...Input... *snif* *snif*10
-
I just can't...the boss just told me that we don't need to make sure that the user is logged in order to make a subscription payment...I tried ( in 3 diff ways )... but his reponse was :
- don't worry, we will figure it out later
now I can't properly finish the task and have to remove the force login... so if the user is not logged he just give us his money for nothing...
then after some tume will come the next dev and will start curse me...19 -
I love when I compile. Then I’m missing one character in a listener function. Compile again. Oops one other character. Compile again. Well WAHT the fuck is it now? I once spent two hours looking for an error in my CSS and my diff program (beyond compare) didn’t show spacing changes in a line.1
-
Right now I am doing job in non-tech firm. There people are so diff. I feel they are rainbow as my life is black n white. I got no friend there its been 10 weeks. May be because I dont talk much or may be bc I dont share my food.
Aahhh even I like staying alone. People sucks.5 -
Clouwn world !
Microsoft 4-5 years ago : "hey we put in place a small Ai calculator "advisor" for you to check. Maybe you can pay a bit less"
People using advisor and puting it in yearly mode to how much diff it would take over a year.
Microsoft : Fuck people are paying less. Then see image...
I only see one reason for that. -
I need to compare the JSON results of an API before and after a code change. But it was also moved to another API.
However some fields are auto-generated like timestamp or derived off the url (resource links).
Also if a JSON list is returned it maybe in different order...
Wondering is there a quick way to test text likeness?
I've done it before but just used matching status code and maybe measuring the diff in response size7 -
When you havent pushed in ages and have to tediously 'git status' followed by 'git diff <every fucking file>' to figure out what the hell you've even been doing since the last push and can maybe figure out another commit message than "Various bugfixes"
-
I prefer VSCode over visual studio for a ton of tiny conveniences. Some git operations can really only be done conveniently by switching rapidly between the command line and the big scrollable list of diffs. The currently open file is automatically focused in the tree, not by explicit user command. Ctrl+Tab shows the last viewed section of files and not their name, so I can find an arbitrary point in my jump chain. If I open the diff for a newly added file it's possible that I want to edit the file, but it's also possible that I didn't notice that it's newly added. Painting the whole background green doesn't hinder the first scenario nearly as much as it solves the second, in contrast to VS not showing any changes, which just has me confused because of the total lack of modification marks.3
-
First rant ever:
So I occasionally have to work for managers who say things like: "Don't reformat that code, the diff will look confusing in our repo browser". Said with such conviction that they initially made me feel retarded when I was more junior.
As time went on I realized that if we tried to "preserve" code so that the only changes visible were those that resulted in functional changes to our app, our code would eventually degrade into a steaming pile of unreadable piss.
I thankfully am working for a more technical manager at the moment so I don't have this issue and can make small refactors to make the codebase less gagworthy as I go.
I don't know though, maybe I'm wrong. Thoughts?2 -
Just a friendly note: If you use the same technique as I i.e. local GIT repositories backed up on cloud, ALWAYS make sure there is still at least as much free space as the largest repo shallow clone.
It may happen that some really really archaic "commits" will disappear and git won't work as usual, but mostly you'll have an access to the branches, which you can diff against the master and make patches. Then just clone, make branches from patches and code happily ever after.
Also... you really really shouldn't push when you discover(git fsck --all) such an issue in your local repo, although I think git won't even allow you to do so. -
fuck, fuck, fuck, fuck, fuck, FUCK
second day I can't configure the stupid pass for mysql root...
I got in, executing maybe 3 diff queries and all seems good, but when I try to use it, nope, is not that
I had to be done already w/ the assignment and here I am still configuring...10 -
I might sound stupid, but why don't solo-developers use things like dropbox for active file history that keeps track of every change and also gives diff options and up to 1 year log - instead of git?
Don't get me wrong, git is amazing when you have to work with a team or multiple people in general, but it's simply a pain in the ass when working alone and having to keep track of every state yourself.6 -
That moment when I suddenly notice that I've been working for two days on my repo that is hosted on Microsoft Team Services, while the active repo is hosted on Gitlab
Luckily changes where on a sub library can be managed to integrate a diff1 -
To the electronic/hardware devs here: do you know a (good - optional) diff tool for schematics/PCBs that is independent of a certain ECAD tool?
So far I know of cadlab.io, but I'd really like to have another possibility than an online service.3 -
Coworker just showed me how he avoids merge conflicts and I'm undecided on it. We use feature-branch workflow, so if a feature takes a long time to finish, it may mean merging master multiple times. He avoids it by stashing changes instead of committing them, then when he needs to merge master into the branch it's still clean. When the feature is done and he's ready to commit, he pops the changes and git diff shows all the changes before you push and you just change what you need instead of being forced to use the horrible merge software.
There must be problems with this, right? This seems too easy for it not to be the standard.5 -
Sometimes, using git feels like performing a particle experiment in physics.
When I have some added lines staged for a commit, then remove those lines and stage it too, the changes annihilate into no changes at all.
Lines add and lines remove is like particle and antiparticle.
The energy that is released upon annihilation is equivalent to the joy of having a clean commit with few changes.2 -
Learn what blobs, trees, hashes and the concept of "commiting" (transactions) are.
Then learn how to use diff/patch.
Then learn Git.
In that order. -
When a company makes changes to their Privacy Policy, they just have to provide the diff of the agreement.
-
Sitting outside of the office trying to find some peace and fresh air..could be spacing out.
other might think that i was facing the problems and looking defeated.
our perspective is diff. dont assumed my life is suck like yours. -
Fuck you google for changing the filters in the chrome console. Before I could ignore warnings if they were fixed by another teammate in a diff branch. Now I have to go over 20 fucking lines of missing exports from a common lib file, which has 0 impact on my current work, because google decided to treat devs as retards.
If you dont know:
Before I could pick whichever outout I want (log, debug, warnings etc), and now I can only use "verbose", "info", "warnings" and "errors" 😡 -
Can you imagine npm would manage autonomous robots?
and also some horrible mistake would need fix, otherwise somebody would be harmed.
for that you push the update, you did npm outdated 3 days ago, everything looked fine.
Npm outdated today would want you to update by 10 versions. I don't know if I'm alone, but seems weird to me that 10 versions jump has happened ... :D we know npm..
and even weirder is the output of npm outdated compared to what package.json diff: express-status-monitor current version1.1.0 latest 1.1.2 -
No google I don't want result about marketing, features of set Software.
I want fucking answers why the fuck our merge tool that comes with that stupid software does not work! And setting an alternative also does not work!
Just Answer my fucking question!
Setting up "tool" with "Source Control client" or alternative. -
Just finished cleaning up my branch so it can be merge. The PR's Diff is massive... probably the largest on the team based on new lines of code.
Basically a migration of a massive report that took almost 2 years to resolve most of the diffs.
Now just need to get it ready production... By next weekend -
Ok. I GIVE UP! ...for at least a couple hours...
I'm not a big believer in... well anything suitable to the literal definition of believe. But there's only so much 'wtf? How is this even possible?' and any answer u can come up with is nearly statistically impossible...
I am a neuro-atypical (and just extremely atypical even if i somehkw was neurotypical) being, based on logic, finely calculated statistical probability and the most raw data and as unbiased as realistically possible, algorithms and interpretation (usually recursive pattern recognition with several highly detailed historical sources.
...but at some point statistical improbability and a collation of separate, yet relatively closely occuring events/circumstances makes logic, itself a primary suspect of corruption.
What was the breaking point that caused me to (temporarily) give up and tell logic to f off for a bit cuz maybe the illogical and mythical is the real logic, leaving me in a losing battle with 'the' fates?
Trying to get all my sourcing/purchase orders in/paid for/on the literal boats b4 end of the workday/week in china...
1st, had to drop a supplier cuz they have limited reps. When the one ive had 7+ years left, i got the aloof blonde girl societal trope of a rep... who for the 2nd time (despite the several very blunt complaints above her, incl me) she sent out a promotional update to the entire client list (ie, inherently competitors) as CC not BCC... over 200 business email accounts with tailored info of their sourcing.
2- totally diff company/ industry a former rep i was glad be rid of apparently just sfarted back for "awhile" as i needrf to restock/scale...apparently she forgot everything we discussed at length... lke if you want a chance on my business im not gonna be wasting time looking through your gui "mini store to then inquire about everything individually insead of a simple spreadsheet(which i print and put in a 3-ring binder rotating current catalogues in the same format i require everywhere)
3.dog was an ahole, my packed schedule got delayed and morphed.. a bunch of little bs thatd normally have no extra thought impact, hyperfocused forgetting one of my alarms til i realised my idiopathic fever was back and i didnt take/apply meds (pain/muscle relaxers mainly so despite this odd free time and needing to shower. I gotta sit on my rear, leg elevated/non-productive far 40min b4 i can shower (as functional legs and lack of syncope is almost a req to shower)
4. A new-ish rep of a company/factory i like/respect enough to not mention in relation... he makes invoice 1.. slight error thst was easily resolved...#2 was flawless... he goes to officially generate the contract(alibaba... verrrry simple with lots of extra explanation buttons). Price and all items match, its near workweek end so i was waiting for it so i could quickly pay/have it on the boat b4 it left and few fdav days are behind...
I put in card info, get to the 2 cbeck boxes (imo should be only 1 but whatever) asking if billing address is same ss delivery(its always default yes)... then i see a few lines in chinese (i can read enough for business negotiations... typical words/sentences innately look different than things like individual letters/address and postal indicators.) After a few loops of double checking, mentally trying to dismiss my i Intial judgement cuz it'd be too ridiculous... even resorted to google .... nope... initial wtf was spot on... recipient name/address was indeed the company(multi factory producer)i was purchasing a wholesale, via sea freight, bulk of products from.
Im pretty sure the system would've flagged it as an invalid contract within an hr... but seriously... ive been handling alibaba (and other) international sourcing since before high school(mainly small businesses i made sites/little tools for that found anything with a light up screen intimidating) and a purchase then shipment to the originating company/factory actually entered into a contract(the form is sooo simple)... im faced with ridiculously improbable obstacles actually existing and changing in such nonsensical statistically improbable ways so often that 1. I wouldn't trust a dr (or most humans) that didnt 1st assume i was crazy of some form...unfortunately im not, despite hkw much simpler and probable itd be 2. Id be super suspicious/converned if statistic norms were my norm for over a day.
But seriously wtf???
Someone give me some wisps of a frame of ref here... where's a typical 'fuck this, im out!' Breaking point?1 -
Want to open all the files changed in a PR?
> code $(git diff master --name-only)
#git #vscode #vscodehacks4 -
I work on a larger team where we do continuous integration so there is a high probability people will be working on the same files for different features. As a result, one of the best feelings is grabbing the latest files and not having to diff first thing in the morning.
-
!dev
I'm on vacation this week but spent yesterday going to the post office for the Nth to follow up on undelivered mail. When got a diff package that said was delivered... But wasn't.
This morning wake up feel sorta sick but was OK, called USPS mail number and waited 1hr to get a person. And they said the post office closed all the cases I raised regarding the missing mail.
They said they will escalate these.. Which and to be just we'll do something, eventually maybe.
After the call I felt tired so went back to bed... Woke up 3hrs later (1pm) and sorta sweaty. Maybe a cold/fever.
I have an hard to schedule appointment with doctor tmr.
So took some meds and now hoping I feel better tmr and don't have COVID..... Just so I don't need to cancel...
And if I do go there only news I expect to hear is they discover some new health problem.
Some vacation this is.... Still gotta deal with the unending onslaught of problems in life....8 -
Should I get ultrabook or gaming laptop
Any suggestions
Never played much games but gaming laptop will give me overall a better hardware
Or should I choose portability over it
Experienced people please help
Do you literally feel much diff carrying gaming laptop compared to ultrabook on day to day basis16 -
Anyone here do animation?
So I'm developing this command-line animation program. It'll obviously only be for quick stuff
I'm thinking of accepting frames and an expression to order, overlay and diff/patch frames.
What kinds of things should I implement? I have done basically no animation ever.
Previous post: https://devrant.com/rants/2312640/...
PS join the chat! https://gitter.im/animator-project/...
https://github.com/skuzzymiglet/...2 -
'Cuz every time we merge, I get this feelin'.
And every time we merge, I swear I could diff.
Can't you see my merge conflict, wanna force push commits,
in the remote history of Git
https://youtu.be/4G6QDNC4jPs?t=323 -
If I'm in a merge conflict and have the Diff Editor open (REMOTE, LOCAL) which file is the final copy that will be "saved"?2
-
So I was trying to diag this lady tower bc she claims she had a virus that I had told her was only adware. But annnnyyways I told her go ahead bring it in ill look at it. So I plug in my vga cord and no connection I used 2 diff monitors two different cords annnnnnnddd tried to plug it into the TV. There was no connection. Even opened it up everything looked fine. I told her for some reason Im not getting connection so come get it. Long story short she called me back to tell me not only does her computer works and but the virus are gone lol Waste of my time :(
-
Why is the GitHub compare functionality hidden? After going through all the repo views I had to actually Google how to do it, and apparently you HAVE to append "/compare" to the repo URL... is it to save bandwidth, or hide a buggy feature?...1
-
me: <checking diff of code, types "diff">
comp: error in command provide filenames
me: wtf...
me: oh, "git diff"
me: What's the diff?
Could a diff diff if a diff did not diff code? What?1 -
Since tar is apparently faster than cp
It’s making me wonder
Which is faster
Md5/sha with a comparison against the copied files
Or diff ?5 -
3 hotel wifis (in this order):
Unstable, weak and needed to go to a diff building
Literally admin:admin@gateway
WPA (why the fuck did they even >downgrade< the security from the default...) -
gitlab if i put you in side to side diff mode, but its a new file or only additions, just be in line
pls , i know u got the money and smart engineers to do this -
git merge "conflicts"
(not really an issue, but still a waste of time and concentration, when every now and then, using more than one branch, small edits, merge, and rebase, git diff complains about "conflicts" that are obvious to solve for a human but still not for a machine, despite the hype about the age of AI, coding co-pilots and the like...)5 -
PHP's array_diff()
Simplifies everything from diff-ing two collections to finding model differences. -
Not best practice whatsoever because the box was most likely owned, but...
SSH kept defaulting back to port 22 when it wasn't supposed to. So, wrote a cronjob that checked diff between SSH config and backed up SSH config. If different, reload backup. Didn't get locked out again.
Box has of course been replaced.2 -
I've been working on an extremely intermittent bug for the past week in my project that occurs during a stress testing between a PC based server and an embedded device that share files. When the crash happens, I analyze what happened by looking at a file as a result of an fwrite, look at a diff of it, look at the packets etc. For the past 3 days I had been lead to believe there was a bug in stdio.h's fwrite due to a file being written looking like it was truncated in the diff, but the packets telling a different story (X bytes sent to be written, on the result I report X bytes written). Today I noticed that there was either a bug or an issue in the diffing algorithm that led me to think my code was the issue. I spent 3 fucking days trying to figure why fwrite was truncating and lieing about its result when my diff tool was the culprit. FML.
-
can't see what i'm doing wrong in terms of syntax, or what required field im supposedly missing
visual comparison against older example IDE is happy about can't see difference
copy paste workign example and update params to what i want for new one, seems happy
i fucking hate you typescript
i guess i should've put this shit through kaleidoscope or any other advanced diff, if i owned any or cared
if i need to debug further ill consider it2