cdruc

1.3K posts

cdruc banner
cdruc

cdruc

@cdruc

https://t.co/dTI0ViIgiA

Iasi Katılım Mart 2010
29 Takip Edilen445 Takipçiler
cdruc
cdruc@cdruc·
@dhh some mfs simply have more horsepower
English
0
0
0
37
DHH
DHH@dhh·
Hilarious how we used to earnestly discuss whether the 10x programmer was real.
English
136
40
2.1K
200.3K
cdruc
cdruc@cdruc·
@func25 The only way I see around this is either a higher types package, or somewhat duplicating the types. post has an posts.Author type, not user.User media has a media.Owner, not user.User user has []user.Post isolated but kind of duplicated? :(
English
1
0
1
102
cdruc
cdruc@cdruc·
@func25 Thanks for the article! I read it, but there are still many scenarios... - relationships are hard. Example: posts, users, and media. // building the full representation (not just referencing IDs) posts has an author and []media users have posts and media media has user
English
2
0
2
166
Phuong Le
Phuong Le@func25·
If you are building a Go API and you are stuck on folder structure, then structure your code around features, not around technical layers. Many beginners copy a layout like project/ │── cmd/ │ └── api/ │── internal/ │ │── handlers/ │ │── services/ │ │── repository/ │ │── models/ │ │── middleware/ │ │── database/ │ └── migrations/ and put all user files in each of those folders. It looks professional. But as the app grows, one feature gets scattered across many places. A single change to "users" can require jumping through 5 folders. That makes ownership unclear and slows debugging. --- A more scalable solution is feature-first. Put related code together: - a users package can contain what users need, - a posts package can contain what posts need, and - shared code can live in a small shared package only when truly needed. Inside each feature, you can still separate files by role if necessary. This gives better locality: when you modify a feature, most of the code you need is close together. project/ │── cmd/ │ └── api/ │── internal/ │ │── users/ │ │ │── handler.go │ │ │── service.go │ │ │── repository.go │ │ │── types.go │ │ └── routes.go │ |── posts/ │ |── invoice/ --- Do not over-design too early. A lot of teams start with fewer packages than they think they need. Sometimes one package is enough for a while. Then split when pain appears, not before. Go style generally favors practical simplicity over big upfront structure plans. --- A related point is naming noise. - File names do not need to repeat the package name, - object names do not need to repeat the package name, and - method names do not need to repeat the type name. If the package/type already tells the story, shorten the inner names. It improves readability fast. --- Keep types near where they are used, instead of creating a giant global “models.go” bucket. And if two features start depending on each other, do not let them import each other directly, define smaller interfaces at the consumer side and keep dependency direction one-way. --- So the real goal is simple: when you add or change one business capability, you should mostly work in one place. - If a package has too many unrelated reasons to change, it’s mixed. - If every small change forces edits across many packages, boundaries are wrong.
English
26
42
558
32.6K
cdruc
cdruc@cdruc·
these ais are making me smarter and dumber at the same time smarter = better at design because i get to iterate quickly and many more times almost for free dumber = barely write any code by hand
English
0
0
0
48
cdruc
cdruc@cdruc·
@jeffrey_way my workflow is… open a new chat tab when i think whatever i want do next won’t touch the same files the current clanker is touching
English
0
0
1
82
Jeffrey Way
Jeffrey Way@jeffrey_way·
I'm pretty convinced that very very few developers are actually doing these super-sophisticated workflows that involve a dozen agents working concurrently in their own respective worktrees. Twitter/X would have us believe the opposite is true, weirdly.
English
177
22
706
54K
cdruc retweetledi
History Defined
History Defined@historydefined·
Iraqi prisoner of war comforting his 4-year-old son in Najaf, Iraq, March 31, 2003
History Defined tweet media
English
141
4.8K
25.4K
2.4M
cdruc
cdruc@cdruc·
@_sn_n she was. pick a better candidate next time.
English
0
0
0
9
cdruc
cdruc@cdruc·
@Mmonkoaa that kimmich incident should've followed with a two footer or an elbow in the face.
English
0
0
0
54
cdruc
cdruc@cdruc·
@wesbos @trashh_dev I had the above problem with the diffs lingering around, but more recently I had an even worse one: *not* showing *all* the diffs i swear i'm so close to becoming a vim nerd
English
0
0
0
14
Wes Bos
Wes Bos@wesbos·
Does cursor have some sort of "keep things I already comitted" I keep finding these things from many days and branches ago because I forgot to click them
Wes Bos tweet media
English
54
1
446
55.3K
cdruc
cdruc@cdruc·
@StephenKing release the tooth fairy and santa claus
English
0
0
0
3
Stephen King
Stephen King@StephenKing·
Release the Epstein files. UNREDACTED.
English
2.2K
14.5K
101.7K
3M
cdruc
cdruc@cdruc·
@wesbos @trashh_dev Version: 2.4.23 (Universal) VSCode Version: 1.105.1 Commit: 379934e04d2b3290cf... Date: 2026-01-29T21:24:23.350Z Build Type: Stable Release Track: Default Electron: 39.2.7 Chromium: 142.0.7444.235 Node.js: 22.21.1 V8: 14.2.231.21-electron.0 OS: Darwin arm64 24.6.0
English
0
0
0
37
cdruc
cdruc@cdruc·
@trashh_dev @wesbos you guys must be on an older version or smth. works fine as long as you have that “auto accept on commit” toggle on 😬
English
2
0
1
61
trash
trash@trashh_dev·
@wesbos this is one of my pain points. idk how to fix
English
2
0
40
2K
Spencer Hakimian
Spencer Hakimian@SpencerHakimian·
🚨WOW Jerome Powell MOGS Scott Bessent MIC DROP!
English
49
655
4.5K
259.6K
cdruc
cdruc@cdruc·
@BillAckman yes. this totally looks like something kanye would write
English
0
0
0
33
cdruc
cdruc@cdruc·
“ I am not Iranian and I don’t have any ties to Iran, but I care enormously about humanity. ” oh boy, we know exactly what you are.
Bill Ackman@BillAckman

Mr. President @realDonaldTrump, the IRGC are among the most evil people in the world. I know I am not telling you anything that you don’t already know. I remind you that they have attempted to assassinate you more than once. I would strongly encourage you not to negotiate with them as leaving them in power continues their ability to inflict evil on the world. And their word means nothing. As I write, they are indiscriminately shooting young and old women and girls in the face and in the back just for protesting on the streets. You have made a public commitment to rescue and help the anti-regime protesters which has motivated tens of thousands of additional protesters to go to the streets, and tragically thousands more have died as a result of their doing so. You have kept your word with all of your public statements which has returned the U.S. to being a superpower and made you into one of the greatest presidents in our 250-year history. And importantly America’s word now means something again and the world is much safer as a result. If America walks away from the Iranian people, it will be an even more catastrophic blood bath and a massive missed opportunity for the U.S. and the world. I am not Iranian and I don’t have any ties to Iran, but I care enormously about humanity. This is an incredible opportunity to bring an enduring peace to the world and to shut down one of the most evil and powerful regimes with the support of the Iranian and American people and hundreds of millions and perhaps even billions of other people around the world. God bless Mr. President. The world’s future is in your hands.

English
0
0
4
255