News for hackers. Stuff that matters.
Re:Continuous Unix commit history from 1970 until today by self_awareness on Tuesday March 19, 2019 @09:45AM (#19430712)
https://github.com/dspinellis/unix-history-repo/blob/386BSD-...

    void
    dingdong()
    {
     /* RRRIIINNNGGG RRRIIINNNGGG */
    }
    
    setalarm(n)
     int n;
    {
     signal(SIGALRM, dingdong);
     alarm(n);
    }
:)
Re:Continuous Unix commit history from 1970 until today by saghm on Tuesday March 19, 2019 @02:59PM (#19434341)
I haven't written C in a bit, so I'm a little confused about the second part of that snippet; is `setalarm` a macro? It doesn't look like a function declaration, as there's no return type, and the presence of `int n;` after `setalarm(n)` makes it seem like it would be shadowing `n` if `n` were a parameter rather than an argument (not to mention the fact that `int n;` is outside of the braces. Given that `setalarm` doesn't seem to be declared/defined anywhere in that file, can anyone who's a bit more familiar with the codebase point out to me what's going on here?
Re:Continuous Unix commit history from 1970 until today by jcelerier on Tuesday March 19, 2019 @03:20PM (#19434604)
it's pre-ANSI C function definition
Re:Continuous Unix commit history from 1970 until today by JdeBP on Tuesday March 19, 2019 @04:10PM (#19435212)
There was a time when "I haven't written C in a bit" was a reason for immediately recognizing code such as this. (-:
Re:Continuous Unix commit history from 1970 until today by ktpsns on Tuesday March 19, 2019 @09:03PM (#19437871)
Interestingly, this way of function definitions is "still" the way subroutines/functions are defined in (modern/all time) Fortran (if one ignores the syntactic differences). Also, at "old" C, declarations only may come at the beginning of a block -- just as it still is with Fortran. Out of curiosity, is there any reason for the similiarity?
Re:Continuous Unix commit history from 1970 until today by ethhics on Wednesday March 20, 2019 @10:12AM (#19442344)
At least for the declarations at the beginning of the block, that allows for very simple compiler design as it is very easy to split the code and data sections. Start off allocating space for all the variables it sees, and then when it reaches something not a declaration or definition, start emitting assembly.
Re:Continuous Unix commit history from 1970 until today by Aardwolf on Tuesday March 19, 2019 @07:19AM (#19429758)
The good news is that all commit times fit in the unix timestamp which started in 1970 :)
Re:Continuous Unix commit history from 1970 until today by ComputerGuru on Tuesday March 19, 2019 @09:46AM (#19430717)
I mean, that's not a coincidence.
Re:Continuous Unix commit history from 1970 until today by eclipxe on Tuesday March 19, 2019 @01:03PM (#19432805)
thatsthejoke.jpg
Re:Continuous Unix commit history from 1970 until today by mci on Tuesday March 19, 2019 @08:58AM (#19430310)
The repository unearthed the long lost source code of the original style and diction tools by Lorinda Cherry: https://github.com/dspinellis/unix-history-repo/tree/BSD-4_1... GNU style and diction are their faint copies.
Re:Continuous Unix commit history from 1970 until today by cobbzilla on Tuesday March 19, 2019 @07:19AM (#19429761)
As a piece of history and source for research, this is simply amazing. They show an example of `git blame` on `pipe.c` that includes names like Ken Thompson and Bill Joy; pretty cool.
Re:Continuous Unix commit history from 1970 until today by JdeBP on Tuesday March 19, 2019 @10:13AM (#19430947)
It is important to realize that it does have some gaping holes, though.

For example: I was recently unable to unearth from it exactly when the BSD ps command changed to using getopt() and minus signs for arguments. The entire history of the FreeBSD repository back to the original 4.4BSD commits has ps using getopt(), and minus signs have been the only option syntax documented in the ps(1) manual page for all of that time, too.

* https://svnweb.freebsd.org/base/head/bin/ps/ps.c?revision=15...

* https://svnweb.freebsd.org/base/head/bin/ps/ps.1?revision=15...

This repository, alas, does not yield very much further information.

Re:Continuous Unix commit history from 1970 until today by JdeBP on Tuesday March 19, 2019 @10:44AM (#19431230)
For the curious: The furthest back that I have managed to trace it so far is 1986, using Usenet archives. A patch that was posted to mod.sources on 1986-08-01 (v06i083, Michael A. Callahan) apparently references getopt() argument parsing and mentions "ps -U", implying that 4.2 BSD ps was using getopt() by then. (Although there's no direct mention of getopt and this may be wrong.)

* https://groups.google.com/d/msg/mod.sources/H-shkbdVIbs/VJUI...

Re:Continuous Unix commit history from 1970 until today by nes350 on Tuesday March 19, 2019 @10:47AM (#19431262)
Found it interesting someone has created a GitHub account for Dennis Ritchie: https://github.com/dmr-1941-2011

Note how the year selector on the right of "Contribution activity" is broken - seems it can't fit 1970-2019. Same happens with Ken Thompson's profile.

Re:Continuous Unix commit history from 1970 until today by ianbooker on Tuesday March 19, 2019 @07:21AM (#19429773)
As linked in the repository: https://youtu.be/S7JB0mhrGCQ

For this alone, all the work paid off.

On a more serious side, I wonder what we can learn from this data. Its not a question for the field of computational social science, but social science of computation!

Re:Continuous Unix commit history from 1970 until today by emidln on Tuesday March 19, 2019 @08:04AM (#19430005)
It would be interesting to do this for one of the open source Solaris distros and for plan9 to then compare the three.
Re:Continuous Unix commit history from 1970 until today by zeckalpha on Tuesday March 19, 2019 @08:47AM (#19430215)
It’s missing those specifically, but http://fxr.watson.org has quite a few kernels
Re:Continuous Unix commit history from 1970 until today by e40 on Tuesday March 19, 2019 @10:47AM (#19431261)
The main product I work on started in RCS, moved to CVS then to git. I have continuous history going back to 1988.
Re:Continuous Unix commit history from 1970 until today by atm0sphere on Tuesday March 19, 2019 @10:51AM (#19431305)
What is it?
Re:Continuous Unix commit history from 1970 until today by e40 on Tuesday March 19, 2019 @02:07PM (#19433642)
Closed source language product, though parts are open source, like this:

https://github.com/franzinc/clim2

First commit 1991.

Re:Continuous Unix commit history from 1970 until today by notpeter on Tuesday March 19, 2019 @11:04AM (#19431446)
> This repository will be often automatically regenerated from scratch, so this is not a place to make contributions. To ensure replicability its users are encouraged to fork it or archive it.

I've run into this with source code archeology projects. Git is ill-suited to integrating newly discovered pre-history/missing intermediary history steps. Any new historical change, out of necessity, alters all subsequent commit hashes. This means collaboration and permalinks can't happen like with "normal" Git repos.

Does anyone know of any tooling or an alternate vcs which has the ability to integrate new pre-history or alternate history (e.g. original branch commits alongside a squash and merge commit) without requiring completely breaking/re-writing the entire tree?

Re:Continuous Unix commit history from 1970 until today by Rondom on Tuesday March 19, 2019 @11:56AM (#19432020)
Git has a mechanism to declare two commits equal and replace one with the other: man git-replace

This comes at the cost of having intentionally multiple histories and is not well-suited for complicate cases, but for the common case of "we want to stitch this old CVS-history to this commit", it does a good job.

Usability-wise, replace refs are not cloned automatically and some web-based tools lack support for it.

Re:Continuous Unix commit history from 1970 until today by yebyen on Tuesday March 19, 2019 @03:01PM (#19434370)
You can also use the 'magic empty tree object' to make your repo more amenable to joining disparate histories of other trees. It requires both the source and destination repo to abide by this practice, but I do this on all of my repos...

Immediately after `git init`, do `git commit --allow-empty -m"initial empty commit"`. Now you have an empty commit, and any other repo which has this empty commit has some history in common with your repo.

The SHA-1 hash is well-known and there are plenty of articles you can find about it, if you search for 4b825dc642cb6eb9a060e54bf8d69288fbee4904

Here's one for example:

https://stackoverflow.com/questions/9765453/is-gits-semi-sec...

I'm not sure this helps for projects which have a shared development history, but not a shared commit history. But within an organization, where you have projects which may split and/or merge, it can help to bridge some gaps.

Re:Continuous Unix commit history from 1970 until today by dearrifling on Tuesday March 19, 2019 @04:15PM (#19435281)
You can have unrelated commits and roots in a single git repo. No need for empty root commit.
Re:Continuous Unix commit history from 1970 until today by yebyen on Tuesday March 19, 2019 @04:52PM (#19435727)
I think the payoff is for merging unrelated histories, that you can then rebase one history on the other, and present a new unified history.

Is the really only reason why people do this, so that you can rewrite your initial working commit in a rebase? I think that might be it. (You can't easily rewrite the initial commit with a rebase.)

Re:Continuous Unix commit history from 1970 until today by JdeBP on Tuesday March 19, 2019 @09:45AM (#19430714)
For some other github accounts, see https://unix.stackexchange.com/q/320133/5132 .
Re:Continuous Unix commit history from 1970 until today by pjc50 on Tuesday March 19, 2019 @08:45AM (#19430201)
Linked from the README is the tooling: https://github.com/dspinellis/unix-history-make
Re:Continuous Unix commit history from 1970 until today by beckler on Tuesday March 19, 2019 @08:04AM (#19430008)
Git wasn't released until 2005, so what did they use before then? I know it says they pulled the history from 24 snapshots.
Re:Continuous Unix commit history from 1970 until today by dboreham on Tuesday March 19, 2019 @08:18AM (#19430072)
Re:Continuous Unix commit history from 1970 until today by mcv on Tuesday March 19, 2019 @08:44AM (#19430193)
I assumed this history was meticulously reconstructed with a lot of hard work, but apparently Unix was one of the first systems maintained in SCCS.

I guess the part from before SCCS was still meticulously reconstructed?

Re:Continuous Unix commit history from 1970 until today by dboreham on Thursday March 21, 2019 @04:53PM (#19457211)
Poking around a bit in the repo, I think the history prior to SCCS is just release snapshots. e.g. there is no history for the cat command in the PDP-7 Unix : https://github.com/dspinellis/unix-history-repo/commits/Rese...
Re:Continuous Unix commit history from 1970 until today by BuildTheRobots on Tuesday March 19, 2019 @08:16AM (#19430067)
iirc, Linux used to live inside of BitKeeper which was a paid for solution. I believe Linus wrote git as a replacement because he got fed up with the commercial licensing (even though they gave free copies to linux devs).

Edit: this doesn't actually answer your question of where unix used to live, rather than linux though....

Re:Continuous Unix commit history from 1970 until today by brazzy on Tuesday March 19, 2019 @08:56AM (#19430301)
> I believe Linus wrote git as a replacement because he got fed up with the commercial licensing (even though they gave free copies to linux devs).

No - BitKeeper revoked the free license because some guy (unrelated to Linux) wrote a client that reverse engineered more features than BitKeeper liked.

And Linux actually used BitKeeper only between 2002 and 2005; prior to that time, it did not use a source control system at all.

Re:Continuous Unix commit history from 1970 until today by self_awareness on Tuesday March 19, 2019 @09:49AM (#19430739)
The BitKeeper reverse engineering is a fun story to read: https://lwn.net/Articles/132938/ (and short!)
Re:Continuous Unix commit history from 1970 until today by black-tea on Tuesday March 19, 2019 @09:54AM (#19430789)
The funny thing is the "reverse engineering" involved telnetting into the server and typing "help".
Re:Continuous Unix commit history from 1970 until today by d4rti on Tuesday March 19, 2019 @11:39AM (#19431827)
And if I recall correctly it sent back SCCS-style data
Re:Continuous Unix commit history from 1970 until today by black-tea on Tuesday March 19, 2019 @09:53AM (#19430774)
They did use a system---tarballs and patches---but it was just a socially constructed system rather than rigorously enforced using software. Linus has often said he would have rather gone back to that system rather than use CVS or SVN.
Re:Continuous Unix commit history from 1970 until today by cryptonector on Tuesday March 19, 2019 @12:53PM (#19432673)
Fortunately instead he created Git. I'm a fan of Git, though I'm aware many aren't.
Re:Continuous Unix commit history from 1970 until today by js2 on Tuesday March 19, 2019 @10:03AM (#19430860)
The "some guy" was Samba/rsync developer Andrew Tridgell.
Re:Continuous Unix commit history from 1970 until today by cagataygurturk on Tuesday March 19, 2019 @05:41PM (#19436272)
Legacy code.
Re:Continuous Unix commit history from 1970 until today by caprese on Tuesday March 19, 2019 @01:19PM (#19432999)
I wish someone would do this for legal code, starting with federal law with hashes for all representatives

(way I envision it is that their committees being their own branches, along with the chambers of congress

even though its not part of the git protocol, the GUI element of the Pull Request feature could have continuous integration that showed when a threshold of votes were passed to get something into to the next branch like out of committee and onto the floor

then after whichever path was taken to get something codified into law, it is merged into the master branch where the agencies have their own process to update the code of federal regulations)

Re:Continuous Unix commit history from 1970 until today by amyjess on Tuesday March 19, 2019 @02:53PM (#19434273)
> even though its not part of the git protocol, the GUI element of the Pull Request feature could have continuous integration that showed when a threshold of votes were passed to get something into to the next branch like out of committee and onto the floor

I'm wondering if Fossil would be more suited to this than Git.

Re:Continuous Unix commit history from 1970 until today by nukeop on Tuesday March 19, 2019 @01:28PM (#19433120)
I can't believe they used git even in the 70s and they managed to do it all in just 4 commits. Incredible engineers and astounding geniuses.