Skip to content

Instantly share code, notes, and snippets.

@drager
Created April 24, 2019 11:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save drager/a9037b2941ad29440743422bd213c261 to your computer and use it in GitHub Desktop.
Save drager/a9037b2941ad29440743422bd213c261 to your computer and use it in GitHub Desktop.
{ lib, config, ... }:
# https://gist.github.com/joepie91/ce9267788fdcb37f5941be5a04fcdd0f#installing-a-few-packages-from-master
let
nixpkgsRemote = remote: rev: import (builtins.fetchTarball "https://github.com/${remote}/Nixpkgs/archive/${rev}.tar.gz") {
config = config.nixpkgs.config;
};
remotes = lib.mapAttrs (_: nixpkgsRemote) {
upstream = "nixos";
};
in with remotes;
{
nixpkgs.config.packageOverrides = {
# WARNING! Don't name the remote the same as the package you're trying to
# install, the package will get overridden
master = builtins.trace
"Warning: master is impure. Using this might have unexpected consequences!"
(upstream "master");
vscode-1-32-3 = upstream "2c6876d81bee4e0dcfc4bdcf29f391f6f5152c78";
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment