1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-11-23 11:39:46 +01:00

nix-index: use dummy fish package in tests

This commit is contained in:
Robert Helgesson 2021-08-06 22:55:57 +02:00
parent ab6517d34a
commit d490797179
No known key found for this signature in database
GPG key ID: 36BDAA14C2797E89
2 changed files with 29 additions and 6 deletions

View file

@ -1,4 +1,6 @@
{ pkgs, ... }: {
{ lib, pkgs, ... }:
{
config = {
programs.bash.enable = true;
programs.fish.enable = true;
@ -6,8 +8,18 @@
programs.command-not-found.enable = true;
nixpkgs.overlays =
[ (self: super: { zsh = pkgs.writeScriptBin "dummy-zsh" ""; }) ];
# Needed to avoid error with dummy fish package.
xdg.dataFile."fish/home-manager_generated_completions".source =
lib.mkForce (builtins.toFile "empty" "");
nixpkgs.overlays = [
(self: super:
let dummy = pkgs.writeScriptBin "dummy" "";
in {
zsh = dummy;
fish = dummy;
})
];
programs.nix-index.enable = true;

View file

@ -1,4 +1,5 @@
{ pkgs, ... }:
{ lib, pkgs, ... }:
let
fishRegex = ''
function __fish_command_not_found_handler --on-event fish_command_not_found
@ -11,8 +12,18 @@ in {
programs.fish.enable = true;
programs.zsh.enable = true;
nixpkgs.overlays =
[ (self: super: { zsh = pkgs.writeScriptBin "dummy-zsh" ""; }) ];
# Needed to avoid error with dummy fish package.
xdg.dataFile."fish/home-manager_generated_completions".source =
lib.mkForce (builtins.toFile "empty" "");
nixpkgs.overlays = [
(self: super:
let dummy = pkgs.writeScriptBin "dummy" "";
in {
zsh = dummy;
fish = dummy;
})
];
programs.nix-index.enable = true;