Hacker Newsnew | past | comments | ask | show | jobs | submit | pytyper2's commentslogin

Amazon using it is a big endorsement, I would also imagine that they contribute bug reports.


How far do each of you sit from the monitors?


I feel articles like this should recommend an annual income threshold, if you are buying these lattes with a credit card while your checking account is over-drafted then it is going to indirectly affect your retirement. But I do acknowledge that most people reading this are probably not in an over-drafted position.


This is the most important point. Networks are created mostly, not only born into. Success recognizes skill, by developing a skill then ASKING to work for successful organizations(big and small) the network grows naturally.


It would depend on what needs fixing? Are we talking engine internals of the stuff that hangs of the engine?


Typically, diesels are built with maintenance in mind (at least for trucks, no idea what you'd find in a diesel car). The cylinders are sleaved and meant to be replaced every couple 100k miles or so, so the cylinders themselves also last a long time (the sleaves take the brunt of the wear). I think theyre typically less complex than a standard gasoline engine. E.g. they have no spark plugs (and thus no distributor or ignition system), instead glow plugs to start the engine. Possibly more complex in other areas, such as emissions control.

I'm no expert on engines, so the the above may not be entirely accurate or current. Most of my knowledge comes from working for a semi truck/diesel engine manufacturer as an IT intern close to two decades ago and touring factories.


That's about right.


Nothing to my knowledge needs an overhaul yet, nearing 400k miles, and it's just been maintenance and consumables (except the turbo started leaking at 300k miles, which was replaced)


I periodically smoke, yet I don't call myself a smoker. Yet when I buy insurance I buy the smokers plan, the idea being that if I do need to use the insurance I expect the Insurance company to use any information necessary to deny my claim. Should I be worried about this?


Have fun getting any physical activity injury claim denied. Smokers aren't expected to do sports.

/s


What does '/s' indicate?


My lay-brain imagines that a wire of the same "length" could hold much more power that would flow with much less resistance.


Why?


I wish I could answer that, probably some delusional personality trait that wants to study science instead of programming.


That family has been stealing from the plebs for hundreds of years, why is this newsworthy?


Same here. Without staging how do I change 10 files but only commit 3 of them? For example working on a change, then notice a bug that should be fixed now. Currently I just stage the 3 files for the hot bug fix, commit those, deploy, then continue working on the remaining 7 files.


I wonder how much overlap there is between the "staging area is useless" and the "never rewrite history" crowds.

Personally, I use staging area all the time to create a curated set of commits that make logical sense when putting them up for review.

My workflow is generally to keep a very messy history of `XXX` commits until I am happy with what I've come up with. Then reset back to the branch point and using the staging area to build up logical changesets.

I don't care about the history of my coming up with the solution, I care about presenting the solution in a way that makes sense to reviewers, including future me.


Interesting, so you commit things that are different from the code that is sitting in your working directory at the time of the commit?


I use `git add -p` to selectively pick out chunks of code that fit together into commits.

Later on, if I notice that I messed something up, I'll create a fixup commit and do an interactive rebase to squash it back into the correct commit.


In my opinion, `git add -p` should be the default, and a `-a` or alike to forcibly commit the entire working tree. I have developed a habit that I wouldn't feel comfortable if I haven't reviewed the chunks I am going to make into the commit.


While there are many people who don't understand git's staging area, there are far less that understand how to selectively stage/commit chunks, or even that such functionality is available at all.

It should be a crime for people to blindly stage everything. Cleaning up after my colleagues easily falls under the "lost cause" umbrella.


Whereas I don't feel comfortable with untested work, so "git checkout -p" (undo a change) and "git stash -p" (postpone a change) are how I get the workspace clean enough to commit.


Magit, for emacs, makes this workflow a joy. The "instant fixup/squash" features are great.


Yes, all the time. Stage individual hunks or individual lines in `git gui` to clean up history or avoid commiting debugging hash.


How do you test these intermediate commits, given that they're different from what's on disk?


Usually I test the end result. Or the commits are disjoint enough that I am confident that they don't interfere with each other.

If I really care about things being fully correct at each commit, I'll do an interactive rebase and just stop and test on each commit.


In the case of console.log() and debugger breakpoints, that's not a concern.

Often they're disjoint enough that I'm confident that if the end result works, the intermediate commit works, as the sibling commenter mentioned. (Even if not, on many teams it all gets squashed anyway, the intermediate commit message just makes the Pull Request easier to review.)

I can also often easily comment out the uncommitted stuff.

Finally, if I'm really worried about it, after creating the intermediate commit I can just `git stash`, test it, then `git stash pop` and keep working.


CI/CD. I push, it tests, I keep staging and working.


Absolutely. Every single day. Only the most trivial changes result in commiting everything in my working tree.


I think many people (eg the "never rewrite history" crowd) don't understand what history is useful for. Ask yourself now: once a branch is merged into master, why do we even keep the history of master? The answer is simple: to track old versions and regressions. The answer is not so that some historian can come along and work out what you did each day of your career. That's not useful. Nobody cares. Git history is not history. It's a sequence of versions of software each of which you believe could be checked out and used.


Have a commit command line that lists only the three files in question. It's really not that hard. If you're going to suggest more complex scenarios, the answer usually boils down to in practice "you want an interactive commit anyways," with perhaps some form of (unpushed) history rewriting to move patch hunks around between different commits.

The staging area is basically a half-baked, special commit that is easy to do manipulation on but hard to figure out what its actual state is (e.g., show me only the diffs that are in the staging area, or let me figure out what the hell is actually going on if I'm doing a complicated rebase). You know what would be better? Turn the staging area into a full, real commit and lower the friction of editing unpushed history to make it easy to move patch hunks in, out, and between these commits. It would help people who want commits to be atomic and therefore break WIP changes into multiple commits before publishing them for review.


> Have a commit command line that lists only the three files in question. It's really not that hard.

And how would you stage & commit only a portion of the changes made to a file?

(Like the parents, I use the staging area daily, and I am quite thankful for its existence.)


> And how would you stage & commit only a portion of the changes made to a file?

I wouldn't. That code is untested, and I have a thing against committing untested code.

Git stash -p, on the other hand, allows me to select what code should be left in the working directory for testing, with no need for a staging area.


We just assume that when we commit, the code has been tested in the local dev environment. Better not be committing untested code to my repos, that will get you reprimanded.


`git diff --cached` shows what is in the staging area


There's an alias, `git diff --staged`, that I find a little easier to remember.


Do the same as vanilla git:

    git commit those three files
That operation is still not implemented in git/fs, but it's planned.


It is possible to use git stash for that. In addition to being conceptually simpler it also allows you to run tests on the “partial commit” before commiting it.


git stash actually changes what's on the filesystem though (i.e. you cannot randomly open up something that is stashed in an arbitrary text editor).


You could always just unstash things, I suppose. In the context I was talking about, the stash is only used to prepare a commit, and after that you can unstash everything. For longer term stashing I think named branches you easily checkout are a better alternative.


+1 for git stash -- but I don't like the idea of eliminating the staging area.


It's interesting how people always talk about staging individual files. Did you know git supports staging individual lines? This is way more powerful and allows you to begin commiting sooner on any code base.


It's probably not a download it and run it piece of software, there are probably lots of configurations and likely requires the user to provide their own models and trading rules.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: