[bot] treewide: remove unused 'inherit' in let blocks

This commit is contained in:
volth 2018-07-20 19:36:12 +00:00
parent 1a6af9f88e
commit 6d2857a311
60 changed files with 45 additions and 86 deletions

View File

@ -3,9 +3,9 @@
let
inherit (builtins) head tail length;
inherit (lib.trivial) and or;
inherit (lib.trivial) and;
inherit (lib.strings) concatStringsSep;
inherit (lib.lists) fold concatMap concatLists all deepSeqList;
inherit (lib.lists) fold concatMap concatLists;
in
rec {

View File

@ -1,5 +1,5 @@
{lib, pkgs}:
let inherit (lib) nv nvs; in
let inherit (lib) nvs; in
{
# composableDerivation basically mixes these features:

View File

@ -1,9 +1,4 @@
{ lib }:
let
inherit (builtins) attrNames;
in
rec {

View File

@ -8,7 +8,7 @@ with lib.trivial;
with lib.strings;
let
inherit (lib.modules) mergeDefinitions filterOverrides;
inherit (lib.modules) mergeDefinitions;
outer_types =
rec {
isType = type: x: (x._type or "") == type;

View File

@ -1,7 +1,7 @@
{ config, pkgs, lib, ... }:
let
inherit (lib) mkOption mkEnableOption mkIf mkMerge types;
inherit (lib) mkOption mkIf types;
cfg = config.programs.tmux;

View File

@ -4,8 +4,6 @@ with lib;
let
inherit (pkgs) pam_usb;
cfg = config.security.pam.usb;
anyUsbAuth = any (attrByPath ["usbAuth"] false) (attrValues config.security.pam.services);

View File

@ -4,8 +4,6 @@ with lib;
let
inherit (pkgs) stdenv writeText procps;
udev = config.systemd.package;
cfg = config.services.udev;

View File

@ -1,6 +1,6 @@
{ config, pkgs, lib, ... }:
let
inherit (lib) mkOption mkEnableOption mkIf mkMerge types optionalAttrs optional;
inherit (lib) mkOption mkEnableOption mkIf mkMerge types optional;
cfg = config.services.uptime;

View File

@ -1,7 +1,7 @@
{ config, lib, pkgs, ...}:
let
inherit (lib) concatStringsSep getBin mkOption types;
inherit (lib) concatStringsSep mkOption types;
in rec {

View File

@ -4,7 +4,7 @@
with import ./lib.nix { inherit config lib pkgs; };
let
inherit (lib) concatStringsSep intersperse mapAttrsToList mkForce mkIf mkMerge mkOption optionalString types;
inherit (lib) concatStringsSep mkIf mkOption optionalString types;
bosConfig = pkgs.writeText "BosConfig" (''
restrictmode 1

View File

@ -4,8 +4,6 @@ with lib;
let
inherit (pkgs) chrony;
stateDir = "/var/lib/chrony";
keyFile = "/etc/chrony.keys";

View File

@ -2,7 +2,7 @@
let
inherit (lib) mkOption mkIf singleton;
inherit (lib) mkOption mkIf;
inherit (pkgs) heimdalFull;

View File

@ -7,8 +7,6 @@ let
nssModulesPath = config.system.nssModules.path;
cfg = config.services.nscd;
inherit (lib) singleton;
in
{

View File

@ -1,6 +1,6 @@
{ config, pkgs, lib, ... }:
let
inherit (lib) mkOption types mkIf optionalString;
inherit (lib) mkOption types mkIf;
cfg = config.services.kmscon;

View File

@ -7,7 +7,7 @@ let
xcfg = config.services.xserver;
cfg = xcfg.desktopManager.plasma5;
inherit (pkgs) kdeApplications plasma5 libsForQt5 qt5 xorg;
inherit (pkgs) kdeApplications plasma5 libsForQt5 qt5;
in

View File

@ -8,7 +8,7 @@ let
ldmcfg = dmcfg.lightdm;
cfg = ldmcfg.greeters.gtk;
inherit (pkgs) stdenv lightdm writeScript writeText;
inherit (pkgs) writeText;
theme = cfg.theme.package;
icons = cfg.iconTheme.package;

View File

@ -13,7 +13,7 @@ let
wmDefault = xcfg.windowManager.default;
hasDefaultUserSession = dmDefault != "none" || wmDefault != "none";
inherit (pkgs) stdenv lightdm writeScript writeText;
inherit (pkgs) lightdm writeScript writeText;
# lightdm runs with clearenv(), but we need a few things in the enviornment for X to startup
xserverWrapper = writeScript "xserver-wrapper"

View File

@ -2,7 +2,6 @@
with lib;
let
inherit (lib) mkOption mkIf;
cfg = config.services.xserver.windowManager.openbox;
in

View File

@ -2,7 +2,6 @@
with lib;
let
inherit (lib) mkOption mkIf singleton;
cfg = config.services.xserver.windowManager.wmii;
wmii = pkgs.wmii_hg;
in

View File

@ -2,7 +2,7 @@
, python3Packages, gnome3, gtk3, gobjectIntrospection}:
let
inherit (python3Packages) buildPythonApplication python isPy3k dbus-python pygobject3 mpd2;
inherit (python3Packages) buildPythonApplication isPy3k dbus-python pygobject3 mpd2;
in buildPythonApplication rec {
pname = "sonata";
version = "1.7b1";

View File

@ -64,8 +64,6 @@ let
version = chromium.browser.version;
inherit (stdenv.lib) versionAtLeast;
in stdenv.mkDerivation {
name = "chromium${suffix}-${version}";
inherit version;

View File

@ -11,8 +11,7 @@
assert pulseaudioSupport -> libpulseaudio != null;
let
inherit (stdenv.lib) concatStringsSep makeBinPath makeLibraryPath
makeSearchPath optional optionalString;
inherit (stdenv.lib) concatStringsSep makeBinPath optional;
version = "2.2.128200.0702";
srcs = {

View File

@ -15,7 +15,7 @@
, runCommand }:
let
inherit (pythonPackages) python pycrypto pync;
inherit (pythonPackages) python;
plugins = [
{ name = "perl"; enabled = perlSupport; cmakeFlag = "ENABLE_PERL"; buildInputs = [ perl ]; }
{ name = "tcl"; enabled = tclSupport; cmakeFlag = "ENABLE_TCL"; buildInputs = [ tcl ]; }

View File

@ -4,8 +4,7 @@
installExamples ? true,
installEmacsMode ? true }:
let inherit (stdenv.lib) versionAtLeast
optionals optionalString; in
let inherit (stdenv.lib) versionAtLeast optionalString; in
let inherit (ocamlPackages) ocaml camlp4; in

View File

@ -3,7 +3,7 @@
}:
let
inherit (nixpkgs) fetchpatch fetchurl symlinkJoin fetchFromGitHub callPackage nodePackages_8_x;
inherit (nixpkgs) fetchpatch fetchurl symlinkJoin callPackage nodePackages_8_x;
# https://trac.sagemath.org/ticket/15980 for tracking of python3 support
python = nixpkgs.python2.override {

View File

@ -1,7 +1,7 @@
{ stdenv, fetchFromGitHub, pythonPackages, makeWrapper, gettext, git }:
let
inherit (pythonPackages) buildPythonApplication pyqt5 sip pyinotify python mock;
inherit (pythonPackages) buildPythonApplication pyqt5 sip pyinotify;
in buildPythonApplication rec {
name = "git-cola-${version}";
version = "3.1";

View File

@ -17,7 +17,7 @@ infoFile: let
${lib.concatStrings (map (dep: let
inherit (dep)
url sha1 groupId artifactId version
authenticated metadata extension repository-id;
authenticated metadata repository-id;
versionDir = dep.unresolved-version or version;

View File

@ -1,7 +1,7 @@
{ stdenv, pkgs, erlang }:
let
inherit (stdenv.lib) getVersion versionAtLeast makeExtensible;
inherit (stdenv.lib) makeExtensible;
lib = pkgs.callPackage ./lib.nix {};

View File

@ -49,7 +49,6 @@ rec {
*/
callElixir = drv: args:
let
inherit (stdenv.lib) versionAtLeast;
builder = callPackage ../interpreters/elixir/generic-builder.nix args;
in
callPackage drv {
@ -71,7 +70,6 @@ rec {
*/
callLFE = drv: args:
let
inherit (stdenv.lib) versionAtLeast;
builder = callPackage ../interpreters/lfe/generic-builder.nix args;
in
callPackage drv {

View File

@ -6,7 +6,7 @@
let
inherit (stdenv.lib) optional optionals optionalString;
inherit (stdenv.lib) optionals optionalString;
clangHack = writeScriptBin "clang" ''
#!${stdenv.shell}

View File

@ -6,7 +6,7 @@
let
inherit (stdenv.lib) optional optionals optionalString;
inherit (stdenv.lib) optionals optionalString;
clangHack = writeScriptBin "clang" ''
#!${stdenv.shell}

View File

@ -2,7 +2,7 @@
let
useX11 = stdenv.isi686 || stdenv.isx86_64;
inherit (stdenv.lib) optionals optionalString;
inherit (stdenv.lib) optionals;
in
stdenv.mkDerivation rec {

View File

@ -6,8 +6,7 @@
}:
let
inherit (stdenv.lib) getLib optionalString;
inherit (darwin) libiconv;
inherit (stdenv.lib) optionalString;
inherit (darwin.apple_sdk.frameworks) Security;
bootstrapping = versionType == "bootstrap";

View File

@ -11,7 +11,7 @@
let
inherit (lib) extends makeExtensible;
inherit (haskellLib) overrideCabal makePackageSet;
inherit (haskellLib) makePackageSet;
haskellPackages = pkgs.callPackage makePackageSet {
package-set = initialPackages;

View File

@ -28,7 +28,6 @@
}:
let
inherit (stdenv.lib) optional;
wrapper = ./hoogle-local-wrapper.sh;
isGhcjs = ghc.isGhcjs or false;
opts = lib.optionalString;

View File

@ -19,7 +19,7 @@
assert enableSerialization -> boost != null;
let
inherit (stdenv.lib) optional optionals optionalString;
inherit (stdenv.lib) optional optionals;
in
stdenv.mkDerivation rec {

View File

@ -42,7 +42,7 @@
*/
let
inherit (stdenv) icCygwin isDarwin isFreeBSD isLinux isAarch32;
inherit (stdenv) isDarwin isFreeBSD isLinux isAarch32;
inherit (stdenv.lib) optional optionals enableFeature;
cmpVer = builtins.compareVersions;

View File

@ -10,7 +10,7 @@
}:
let
inherit (stdenv.lib) optional optionals optionalString;
inherit (stdenv.lib) optional optionalString;
in stdenv.mkDerivation rec {
name = "freetype-${version}";

View File

@ -12,7 +12,7 @@
assert gtkSupport -> gtk3 != null;
let
inherit (stdenv.lib) optional optionals optionalString;
inherit (stdenv.lib) optional optionals;
in
stdenv.mkDerivation rec {
name = "gst-plugins-good-1.14.0";

View File

@ -18,7 +18,7 @@
assert faacSupport -> enableUnfree;
let inherit (stdenv.lib) optional optionals hasPrefix enableFeature; in
let inherit (stdenv.lib) optional hasPrefix enableFeature; in
/* ToDo:
- more deps, inspiration: https://packages.ubuntu.com/raring/libav-tools

View File

@ -1,8 +1,6 @@
{ fetchurl, stdenv, pkgconfig, intltool, gettext, glib, libxml2, zlib, bzip2
, python, perl, gdk_pixbuf, libiconv, libintl }:
let inherit (stdenv.lib) optionals; in
stdenv.mkDerivation rec {
name = "libgsf-1.14.42";

View File

@ -41,7 +41,7 @@
}:
let
inherit (stdenv) isi686 isx86_64 isAarch32 is64bit isMips isDarwin isCygwin;
inherit (stdenv) is64bit isMips isDarwin isCygwin;
inherit (stdenv.lib) enableFeature optional optionals;
in

View File

@ -1,8 +1,5 @@
{ stdenv, fetchurl, readline, mysql, postgresql, sqlite }:
let
inherit (stdenv.lib) getDev getLib;
in
stdenv.mkDerivation rec {
name = "opendbx-1.4.6";

View File

@ -11,8 +11,7 @@ let
atlasMaybeShared = if atlas != null then atlas.override { inherit shared; }
else null;
usedLibExtension = if shared then ".so" else ".a";
inherit (stdenv.lib) optional optionals concatStringsSep;
inherit (builtins) hasAttr attrNames;
inherit (stdenv.lib) optional optionals;
version = "3.8.0";
in

View File

@ -23,7 +23,7 @@
}:
let
inherit (stdenv.lib) optional optionalString concatStringsSep;
inherit (stdenv.lib) optional optionalString;
inherit (stdenv) isDarwin;
in buildPythonPackage rec {
pname = "pandas";

View File

@ -24,7 +24,7 @@
}:
let
inherit (stdenv.lib) optional optionals optionalString concatStringsSep;
inherit (stdenv.lib) optional optionals optionalString;
inherit (stdenv) isDarwin;
in buildPythonPackage rec {

View File

@ -10,7 +10,7 @@ let
# https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commitdiff;h=330b90b5ffbbc20c5de6ae6c7f60c40fab2e7a4f;hp=99181ccac0fc7d82e7dabb05dc7466e91f1645d3
version = "2.30";
basename = "binutils-${version}";
inherit (stdenv.lib) optional optionals optionalString;
inherit (stdenv.lib) optionals optionalString;
# The targetPrefix prepended to binary names to allow multiple binuntils on the
# PATH to both be usable.
targetPrefix = optionalString (targetPlatform != hostPlatform) "${targetPlatform.config}-";

View File

@ -11,7 +11,7 @@
let
inherit (pkgs) makeWrapper;
inherit (pkgs.stdenv.lib) fix' extends inNixShell;
inherit (pkgs.stdenv.lib) fix' extends;
pythonPackages =
import "${toString pkgs.path}/pkgs/top-level/python-packages.nix" {

View File

@ -7,8 +7,6 @@
let
inherit (lib) toLower;
toolchainName = "com.apple.dt.toolchain.XcodeDefault";
sdkName = "${xcodePlatform}${sdkVer}";

View File

@ -14,8 +14,7 @@ let
_skim = skim;
inherit (vimUtils.override {inherit vim;}) rtpPath addRtp buildVimPlugin
buildVimPluginFrom2Nix vimHelpTags;
inherit (vimUtils.override {inherit vim;}) buildVimPluginFrom2Nix;
# TL;DR

View File

@ -1,8 +1,7 @@
{ stdenv, lib, fetchurl, callPackage, vscode-utils }:
let
inherit (vscode-utils) buildVscodeExtension buildVscodeMarketplaceExtension
extensionFromVscodeMarketplace;
inherit (vscode-utils) buildVscodeMarketplaceExtension;
in
#
# Unless there is a good reason not to, we attemp to use the same name as the

View File

@ -1,7 +1,5 @@
{ stdenv, fetchFromGitHub, openssl, libevent }:
let inherit (stdenv.lib) optional; in
stdenv.mkDerivation rec {
name = "coturn-${version}";
version = "4.5.0.7";

View File

@ -8,7 +8,7 @@ let # un-indented, over the whole file
result = if extraFeatures then wrapped-full else unwrapped;
inherit (stdenv.lib) optional optionals optionalString concatStringsSep;
inherit (stdenv.lib) optional concatStringsSep;
unwrapped = stdenv.mkDerivation rec {
name = "knot-resolver-${version}";

View File

@ -5,7 +5,7 @@
assert crossSystem == null;
let
inherit (localSystem) system platform;
inherit (localSystem) system;
shell =
if system == "i686-freebsd" || system == "x86_64-freebsd" then "/usr/local/bin/bash"

View File

@ -9,7 +9,7 @@
with lib;
let
inherit (python2Packages) python cython buildPythonApplication;
inherit (python2Packages) cython buildPythonApplication;
in buildPythonApplication rec {
name = "xpra-${version}";
version = "2.3.2";

View File

@ -2,9 +2,7 @@
, docutils
}:
let
inherit (stdenv.lib) optional;
in stdenv.mkDerivation rec {
stdenv.mkDerivation rec {
version = "3.4.0";
name = "sshfs-fuse-${version}";

View File

@ -7,7 +7,7 @@
assert stdenv.isDarwin -> ApplicationServices != null;
let
inherit (stdenv.lib) optional optionals optionalString;
inherit (stdenv.lib) optionals optionalString;
in
stdenv.mkDerivation rec {

View File

@ -3,8 +3,6 @@
, buildPlatform, hostPlatform
}:
let inherit (stdenv.lib) optionals; in
stdenv.mkDerivation rec {
name = "findutils-4.6.0";

View File

@ -1,7 +1,7 @@
{ stdenv, fetchurl, pkgconfig, protobuf, openssl, libpcap, traceroute
, withGUI ? false, qt5 }:
let inherit (stdenv.lib) optional optionalString;
let inherit (stdenv.lib) optional;
in
stdenv.mkDerivation rec {

View File

@ -3,8 +3,6 @@
, hostPlatform, buildPlatform
}:
let inherit (stdenv.lib) optionals; in
stdenv.mkDerivation rec {
name = "ddrescue-1.23";