diff --git a/configuration.nix b/configuration.nix index bf25141501b05440e515d67b79a79be34cb57fe6..0b41b6b171a1522ab858c00c30f7847e9a97bf9d 100644 --- a/configuration.nix +++ b/configuration.nix @@ -1,5 +1,5 @@ # This is the entry point for my NixOS configuration. -{ name, path, channel, isIso, extraLayersDir, flakeInputs, flakeOutputs }: +{ name, path, channel, isIso, extraLayersDir, flakeInputs, flakeOutputs, system }: { lib, config, pkgs, ... }: let @@ -45,6 +45,7 @@ in (path + "/configuration.nix") normalSystemConfiguration flakeInputs.homemanager.nixosModules.home-manager + flakeInputs.qd.nixosModules.qd ] ++ layerImports; home-manager = { @@ -55,7 +56,14 @@ in _module.args.isIso = lib.mkDefault false; - nixpkgs.overlays = [ (import ./pkgs) ]; + nixpkgs.overlays = [ + (import ./pkgs) + (self: super: + { + qd = flakeInputs.qd.packages."${system}".qd; + } + ) + ]; # Pin channel in nix path nix.nixPath = [ "nixpkgs=${channel}" ]; diff --git a/machine-manager.nix b/machine-manager.nix index 7f35df850350c832b6b871f756e48f9fc2b5843f..0f07840c4bf248bacc2511657369b8988fe217e8 100644 --- a/machine-manager.nix +++ b/machine-manager.nix @@ -40,7 +40,7 @@ let mkMachineConfig = { name, path, isIso }: { imports = [ (import ./configuration.nix { - inherit name path isIso extraLayersDir flakeInputs flakeOutputs; + inherit name path isIso extraLayersDir flakeInputs flakeOutputs system; channel = machineChannels.${name}; }) ]; diff --git a/pkgs/default.nix b/pkgs/default.nix index 8d7db290bc53179f98499b8b6e8239ca3b8316d4..a7386e0823098c9805b7075973185d315a653d74 100644 --- a/pkgs/default.nix +++ b/pkgs/default.nix @@ -18,7 +18,6 @@ rec { #net-mqtt = self.haskell.lib.doJailbreak hsuper.net-mqtt; net-mqtt = self.haskell.lib.unmarkBroken hsuper.net-mqtt; q = hself.callPackage ./q {}; - qd = hself.callPackage ./qd {}; qbar = hself.callPackage ./qbar {}; }; }; @@ -39,6 +38,5 @@ rec { }; q = self.haskellPackages.q; - qd = self.haskellPackages.qd; qbar = self.haskellPackages.qbar; } diff --git a/pkgs/qd/default.nix b/pkgs/qd/default.nix deleted file mode 100644 index 8b245c8bfb35aac2db01f5c28f7749d2b0bf56b8..0000000000000000000000000000000000000000 --- a/pkgs/qd/default.nix +++ /dev/null @@ -1,11 +0,0 @@ -{ haskell, fetchgit, callCabal2nix }: - -let - repo = with builtins; fromJSON ( readFile ./repo.json ); - src = fetchgit { - inherit (repo) url rev sha256; - }; -in -haskell.lib.generateOptparseApplicativeCompletions ["qd" "qctl"] ( - callCabal2nix "qd" src {} -) diff --git a/pkgs/qd/repo.json b/pkgs/qd/repo.json deleted file mode 100644 index 0a4f831e846e00307047168504724fffec3d7864..0000000000000000000000000000000000000000 --- a/pkgs/qd/repo.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "ref": "refs/heads/master", - "url": "https://git.c3pb.de/jens/qd.git", - "rev": "ec42f49c3c12855022fcaaff007ff9172472f63e", - "date": "2020-12-05T23:21:18+01:00", - "path": "/nix/store/da49nck17db2gi95lcmwq09cxdaiyy65-qd", - "sha256": "16vjnh2x0pqvfzy32rc97gza0ixmr8447jd8s5ippwkf0rc7krns", - "fetchSubmodules": false, - "deepClone": false, - "leaveDotGit": false -} diff --git a/pkgs/qd/update b/pkgs/qd/update deleted file mode 100755 index 15576a3b768686259f255e77ff905b3d665bb3de..0000000000000000000000000000000000000000 --- a/pkgs/qd/update +++ /dev/null @@ -1,7 +0,0 @@ -#!/usr/bin/env nix-shell -#! nix-shell -i sh -p nix-prefetch-git jq - -url="https://git.c3pb.de/jens/qd.git" -ref="refs/heads/master" - -nix-prefetch-git --rev "$ref" --no-deepClone "$url" | jq --arg ref "$ref" '{ref: $ref} + .' > repo.json