This is all assuming you are on 17.03 as I haven't tested my changes against unstable. Leave a comment here if you have any questions.
-
fork https://github.com/NixOS/nixpkgs on github
-
clone it locally:
$ git clone [email protected]:erlandsona/nixpkgs.git $ cd nixpkgs
-
get channel information via git:
$ git remote add channels git://github.com/NixOS/nixpkgs-channels.git $ git remote update channels
-
set up new local branch based on 17.03:
$ git checkout -b local-17.03 channels/nixos-17.03
-
add a remote for my fork:
$ git remote add pbogdan [email protected]:pbogdan/nixpkgs.git $ git remote update pbogdan
-
pick the lightdm changes:
$ git cherry-pick c48e9e386374ae4f3b90dbd64c2c934ce8475a36 $ git cherry-pick 89e9f1473553114619738718173f82af19565063
the c48e9e386374ae4f3b90dbd64c2c934ce8475a36 commit isn't really required but will save having to resolve a merge conflict manually as it's not in 17.03, see NixOS/nixpkgs#24135
-
adjust /etc/nixos/configuration.nix with the new options:
services.xserver = { ... displayManager = { lightdm = { enable = true; greeters = { gtk = { enable = true; cursorTheme = { package = pkgs.gnome3.defaultIconTheme; name = "Adwaita"; size = 32; }; }; }; }; ... }; };
-
rebuild the system using your own fork:
$ sudo nixos-rebuild switch -I nixpkgs=/home/erlandsona/nixpkgs
(adjust the path as needed)
You would need to use -I nixpkgs=/home/erlandsona/nixpkgs
whenever your rebuild. If at some point you would want to use your own fork for your user with nix-env
you can point to it with nix-env -i somepackage -f ~/nixpkgs/
.
If you want to update and get the latest upstream changes from 17.03 you would run:
$ git remote update channels
$ git rebase channels/nixos-17.03