News for hackers. Stuff that matters.
Re:Why SQLite Does Not Use Git by plorkyeran on Tuesday April 10, 2018 @09:40PM (#16807342)
Looking at a file, and then looking the commit which last modified a specific line in that file is a trivial operation in git that I do on a regular basis.
Re:Why SQLite Does Not Use Git by luckydude on Tuesday April 10, 2018 @11:38PM (#16807850)
How long does that take? In BK it's as fast as you can click. If git is like that what tools are you using to do that?
Re:Why SQLite Does Not Use Git by plorkyeran on Wednesday April 11, 2018 @12:01PM (#16812464)
On the largest repos I've worked with `git blame` takes a second or two: long enough to be annoying and make me wish it was a bit faster, but still fast enough for interactive use and well short of the threshold where I would be tempted to context switch after invoking the command. On most repos it's perceptively instant.

I suspect on a HDD `git blame` would be unbearably slow on anything but the smallest of repositories, but it has been many years since I last worked with source code stored on a HDD.

Re:Why SQLite Does Not Use Git by fyi1183 on Wednesday April 11, 2018 @01:28AM (#16808303)

    git log -- filename
Unless the file hasn't been touched for many years in a Linux kernel size repository, that's faster than you can blink.

I do occasionally wish that git blame was faster. Building up a cache of side index information for that would be a nice addition.

Re:Why SQLite Does Not Use Git by takeda on Wednesday April 11, 2018 @11:14AM (#16811924)
That's true, I'm not the op, but changesets get in a way when using git for SCM, where the typical workflow is to merge between two branches on the level of subdirectories.

In my company people simply use checkout to apply changes from another branch, but that doesn't handle well for example file removals. It also creates a completely different commit so the branches diverge more and more, making things like rebase more time consuming.

It is a huge pain, which would not exist if we would use SVN as a backed for example.

Re:Why SQLite Does Not Use Git by fyi1183 on Thursday April 12, 2018 @01:40AM (#16818312)
I agree that that's not well supported, because it kind of goes against the grain of git thinking about project versions rather than file or directory versions.

What you should probably do in this case is use git merge nevertheless, but reset all changes outside of the directory of interest before committing the merge. This way, you get the history of the merge in the DAG, which will make git's merge resolution work.

Unfortunately, I'm not aware of a built-in way of doing this.