Compare commits
No commits in common. "069c5e979a2a06686def6f9ce5e2ede4d51ad3fe" and "89b96240319660f9b79f14bcb82e921749f58543" have entirely different histories.
069c5e979a
...
89b9624031
6 changed files with 2 additions and 134 deletions
|
@ -79,13 +79,6 @@ in
|
||||||
rerere.enabled = true;
|
rerere.enabled = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
# Use nix-index for command-not-found handler
|
|
||||||
programs.command-not-found.enable = false;
|
|
||||||
programs.nix-index = {
|
|
||||||
enable = true;
|
|
||||||
enableBashIntegration = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
# Enable fail2ban because of the OpenSSH server
|
# Enable fail2ban because of the OpenSSH server
|
||||||
services.fail2ban = {
|
services.fail2ban = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
|
@ -45,7 +45,7 @@ self = {
|
||||||
{
|
{
|
||||||
config.nixpkgs.overlays = [
|
config.nixpkgs.overlays = [
|
||||||
( import ./pkgs/overlays/selfExpr.nix { nixpkgsPath = "${self}/pkgs/top-level/impure.nix"; } )
|
( import ./pkgs/overlays/selfExpr.nix { nixpkgsPath = "${self}/pkgs/top-level/impure.nix"; } )
|
||||||
( import ./pkgs/top-level/by-name-overlay.nix "${self}/pkgs/by-name" )
|
( import "${inputs.nixpkgs}/pkgs/top-level/by-name-overlay.nix" "${self}/pkgs/by-name" )
|
||||||
self.overlays.versionInfoFixup
|
self.overlays.versionInfoFixup
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,66 +0,0 @@
|
||||||
diff --git a/command-not-found.sh b/command-not-found.sh
|
|
||||||
index 5f30bad..3854297 100755
|
|
||||||
--- a/command-not-found.sh
|
|
||||||
+++ b/command-not-found.sh
|
|
||||||
@@ -73,51 +73,30 @@ EOF
|
|
||||||
else
|
|
||||||
if [ -e "$HOME/.nix-profile/manifest.json" ]; then
|
|
||||||
>&2 cat <<EOF
|
|
||||||
-The program '$cmd' is currently not installed. You can install it
|
|
||||||
-by typing:
|
|
||||||
- nix profile install $toplevel#$attrs
|
|
||||||
-
|
|
||||||
-Or run it once with:
|
|
||||||
- nix shell $toplevel#$attrs -c $cmd ...
|
|
||||||
+The program '$cmd' is not in your PATH. You can make it available in an
|
|
||||||
+ephemeral shell by typing:
|
|
||||||
+ nix shell $toplevel#$attrs
|
|
||||||
EOF
|
|
||||||
else
|
|
||||||
>&2 cat <<EOF
|
|
||||||
-The program '$cmd' is currently not installed. You can install it
|
|
||||||
-by typing:
|
|
||||||
- nix-env -iA $toplevel.$attrs
|
|
||||||
-
|
|
||||||
-Or run it once with:
|
|
||||||
- nix-shell -p $attrs --run '$cmd ...'
|
|
||||||
+The program '$cmd' is not in your PATH. You can make it available in an
|
|
||||||
+ephemeral shell by typing:
|
|
||||||
+ nix-shell -p $attrs
|
|
||||||
EOF
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
>&2 cat <<EOF
|
|
||||||
-The program '$cmd' is currently not installed. It is provided by
|
|
||||||
-several packages. You can install it by typing one of the following:
|
|
||||||
-EOF
|
|
||||||
-
|
|
||||||
- # ensure we get each element of attrs
|
|
||||||
- # in a cross platform way
|
|
||||||
- while read attr; do
|
|
||||||
- if [ -e "$HOME/.nix-profile/manifest.json" ]; then
|
|
||||||
- >&2 echo " nix profile install $toplevel#$attr"
|
|
||||||
- else
|
|
||||||
- >&2 echo " nix-env -iA $toplevel.$attr"
|
|
||||||
- fi
|
|
||||||
- done <<< "$attrs"
|
|
||||||
-
|
|
||||||
- >&2 cat <<EOF
|
|
||||||
-
|
|
||||||
-Or run it once with:
|
|
||||||
+The program '$cmd' is not in your PATH. You can make it available in an
|
|
||||||
+ephemeral shell by typing:
|
|
||||||
EOF
|
|
||||||
|
|
||||||
while read attr; do
|
|
||||||
if [ -e "$HOME/.nix-profile/manifest.json" ]; then
|
|
||||||
- >&2 echo " nix shell $toplevel#$attr -c $cmd ..."
|
|
||||||
+ >&2 echo " nix shell $toplevel#$attr"
|
|
||||||
else
|
|
||||||
- >&2 echo " nix-shell -p $attr --run '$cmd ...'"
|
|
||||||
+ >&2 echo " nix-shell -p $attr"
|
|
||||||
fi
|
|
||||||
done <<< "$attrs"
|
|
||||||
;;
|
|
|
@ -1,9 +0,0 @@
|
||||||
{self, super, package }:
|
|
||||||
|
|
||||||
package.override {
|
|
||||||
nix-index-unwrapped = self.nix-index-unwrapped.overrideAttrs (oldAttrs: {
|
|
||||||
patches = oldAttrs.patches or [] ++ [
|
|
||||||
./cnfOutput.patch
|
|
||||||
];
|
|
||||||
});
|
|
||||||
}
|
|
|
@ -1,50 +0,0 @@
|
||||||
# Modified copy of github:NixOS/nixpkgs pkgs/top-level/by-name-overlay.nix
|
|
||||||
# as of commit c0d0be00d4ecc4b51d2d6948e37466194c1e6c51
|
|
||||||
|
|
||||||
# This file turns the pkgs/by-name directory into an overlay that adds all the defined packages.
|
|
||||||
# No validity checks are done here.
|
|
||||||
|
|
||||||
# Type: Path -> Overlay
|
|
||||||
baseDirectory:
|
|
||||||
let
|
|
||||||
lib = (import ../../outputs.nix {}).lib;
|
|
||||||
|
|
||||||
inherit (builtins)
|
|
||||||
readDir
|
|
||||||
;
|
|
||||||
|
|
||||||
inherit (lib.attrsets)
|
|
||||||
mapAttrs
|
|
||||||
mapAttrsToList
|
|
||||||
mergeAttrsList
|
|
||||||
;
|
|
||||||
|
|
||||||
# Package files for a single shard
|
|
||||||
# Type: String -> String -> String -> AttrsOf Path
|
|
||||||
namesForShard = nixFilename: shard: type:
|
|
||||||
if type != "directory" then
|
|
||||||
# Ignore all non-directories.
|
|
||||||
{ }
|
|
||||||
else
|
|
||||||
mapAttrs
|
|
||||||
(name: _: baseDirectory + "/${shard}/${name}/${nixFilename}")
|
|
||||||
(readDir (baseDirectory + "/${shard}"));
|
|
||||||
|
|
||||||
# The attribute set mapping names to the package files defining them
|
|
||||||
# Type: String -> AttrsOf Path
|
|
||||||
packageFiles = nixFilename: lib.pipe baseDirectory [
|
|
||||||
readDir
|
|
||||||
(mapAttrsToList (namesForShard nixFilename))
|
|
||||||
mergeAttrsList
|
|
||||||
# Filter out paths that don't have a ${nixFilename} file
|
|
||||||
(lib.filterAttrs (_: lib.pathExists))
|
|
||||||
];
|
|
||||||
in
|
|
||||||
self: super:
|
|
||||||
mapAttrs (name: file:
|
|
||||||
self.callPackage file { inherit self super; package = super.${name}; }
|
|
||||||
) (packageFiles "override.nix")
|
|
||||||
// mapAttrs (name: file:
|
|
||||||
self.callPackage file { }
|
|
||||||
) (packageFiles "package.nix")
|
|
||||||
|
|
|
@ -16,7 +16,7 @@ let
|
||||||
( import ../overlays/selfExpr.nix { nixpkgsPath = "${builtins.toString ../..}/pkgs/top-level/impure.nix"; } )
|
( import ../overlays/selfExpr.nix { nixpkgsPath = "${builtins.toString ../..}/pkgs/top-level/impure.nix"; } )
|
||||||
( import ../overlays/unstable.nix )
|
( import ../overlays/unstable.nix )
|
||||||
( import ../overlays/version-info-fixup.nix { inherit inputs; } )
|
( import ../overlays/version-info-fixup.nix { inherit inputs; } )
|
||||||
( import ./by-name-overlay.nix ../by-name )
|
( import "${inputs.nixpkgs}/pkgs/top-level/by-name-overlay.nix" ../by-name )
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
in
|
in
|
||||||
|
|
Loading…
Add table
Reference in a new issue