I'd like to merge the NixOS tree into the Nixpkgs repository, as has been discussed a few times in the past. The reasons for merging them are:
Changes in Nixpkgs often require a change in NixOS and vice versa. With separate repositories, this means you need to do two commits, which is not atomic and creates the possibility of trees being out of sync with each other.
Branches in Nixpkgs often require corresponding branches in NixOS. For instance, a Nixpkgs branch like multiple-outputs requires a branch in NixOS because it changes the structure of some packages.
Issue tracking: it's often unclear whether an issue should be reported in the NixOS or Nixpkgs issue tracker, and often the fix is in the other repository.
The NixOS version is currently a 2-tuple of Git hashes. Merging NixOS and Nixpkgs allows the NixOS version to be identified using a single Git hash.
There are also downsides to merging:
It makes the Nixpkgs tree a bit bigger, which may be slightly annoying for people who only use Nixpkgs and not NixOS.
It makes it harder to build a NixOS tree against a different Nixpkgs tree. But given the tight coupling between these trees, that doesn't work very well in practice anyway. OTOH, it becomes much easier to use multiple Nixpkgs trees in a NixOps deployment (since there are no more <nixpkgs> references).
I did a test merge, available here: https://github.com/edolstra/nixpkgs/tree/merge-test. It imports nixos/master as a subdirectory "nixos" in the root directory of Nixpkgs (keeping all history). While I was at it, I also renamed pkgs/lib to lib because it never really made sense to have it in pkgs.
Note that GitHub unfortunately doesn't show history across renames, but "git log --follow" does (and GitHub's "blame" also works fine).
@bluescreen303 Yeah, that's basically why I want to do this now. If we do it after the release, we'll have to keep two repositories alive for a while.
For the downsides:
What I'm not clear about: can we somehow "merge" the github issues/PRs? There are quite many for both nixos and nixpkgs.
There is a script to move issues to another GitHub project, but it doesn't keep comment authorship: https://github.com/collective/collective.developermanual/blob/master/gh-issues-import.py
I just wrote a mail to Github asking if they know a way to merge projects while keeping all issues with comments.
I use nixpkgs on Ubuntu on a couple of machines, but still +1 for merging. Looking forward to easily git bisect the whole of NixOS and more easily recreate exact builds (no more manual work to match nixos/nixpkgs versions).
I'm fine with this change, too.
There are more reasons to merge: Eg should "creating an iso or an usb image of nixos" be a nixpkgs or a nixos project?
The more I think about it the earlier this should be done.
Okay, I'll do the merge now. Cross fingers...
I'll turn off commits to the NixOS repo first.
Do we have to reopen pull requests now or will they be handled in any other way?
This can be closed?
Yes, closing now...