parent
ccd7df836e
commit
0b491b460f
200 changed files with 2421 additions and 2817 deletions
|
|
@ -1,9 +1,6 @@
|
|||
# Adapted from Nixpkgs.
|
||||
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.programs.command-not-found;
|
||||
commandNotFound = pkgs.substituteAll {
|
||||
|
|
@ -31,9 +28,9 @@ let
|
|||
|
||||
in {
|
||||
options.programs.command-not-found = {
|
||||
enable = mkEnableOption "command-not-found hook for interactive shell";
|
||||
enable = lib.mkEnableOption "command-not-found hook for interactive shell";
|
||||
|
||||
dbPath = mkOption {
|
||||
dbPath = lib.mkOption {
|
||||
default =
|
||||
"/nix/var/nix/profiles/per-user/root/channels/nixos/programs.sqlite";
|
||||
description = ''
|
||||
|
|
@ -41,11 +38,11 @@ in {
|
|||
default this file will be provided by your channel
|
||||
(nixexprs.tar.xz).
|
||||
'';
|
||||
type = types.path;
|
||||
type = lib.types.path;
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
config = lib.mkIf cfg.enable {
|
||||
programs.bash.initExtra = shInit "command_not_found_handle";
|
||||
programs.zsh.initContent = shInit "command_not_found_handler";
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue