nagiosPlugins.check_smartmon: format with nixfmt-rfc-style

This commit is contained in:
Anthony Roussel 2024-03-24 23:01:30 +01:00 committed by Anthony ROUSSEL
parent 1b96b4289e
commit 96cf86c9bc

View File

@ -1,18 +1,19 @@
{ lib {
, stdenv fetchFromGitHub,
, fetchFromGitHub lib,
, python3 python3,
, smartmontools smartmontools,
stdenv,
}: }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "check_smartmon"; pname = "check-smartmon";
version = "1.0.1"; version = "1.0.1";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "driehuis"; owner = "driehuis";
repo = "Nagios_check_smartmon"; repo = "Nagios_check_smartmon";
rev = version; rev = "refs/tags/${version}";
sha256 = "tiIeFiHdDgqoeznk9XdCE7owIMnnsQ0fmtj8foFoUD8="; sha256 = "tiIeFiHdDgqoeznk9XdCE7owIMnnsQ0fmtj8foFoUD8=";
}; };
@ -24,7 +25,7 @@ stdenv.mkDerivation rec {
postPatch = '' postPatch = ''
patchShebangs check_smartmon.py patchShebangs check_smartmon.py
substituteInPlace check_smartmon.py \ substituteInPlace check_smartmon.py \
--replace '"/usr/sbin/smartctl"' '"${smartmontools}/bin/smartctl"' --replace-fail '"/usr/sbin/smartctl"' '"${smartmontools}/bin/smartctl"'
''; '';
installPhase = '' installPhase = ''
@ -33,11 +34,11 @@ stdenv.mkDerivation rec {
runHook postInstall runHook postInstall
''; '';
meta = with lib; { meta = {
description = "Nagios-Plugin that uses smartmontools to check disk health status and temperature"; description = "Nagios-Plugin that uses smartmontools to check disk health status and temperature";
mainProgram = "check_smartmon"; mainProgram = "check_smartmon";
homepage = "https://github.com/driehuis/Nagios_check_smartmon"; homepage = "https://github.com/driehuis/Nagios_check_smartmon";
license = licenses.gpl2Plus; license = lib.licenses.gpl2Plus;
maintainers = with maintainers; [ mariaa144 ]; maintainers = with lib.maintainers; [ mariaa144 ];
}; };
} }