nixpkgs/pkgs/tools/misc/agedu/default.nix
Profpatsch 4a7f99d55d treewide: with stdenv.lib; in meta -> with lib;
Part of: https://github.com/NixOS/nixpkgs/issues/108938

meta = with stdenv.lib;

is a widely used pattern. We want to slowly remove
the `stdenv.lib` indirection and encourage people
to use `lib` directly. Thus let’s start with the meta
field.

This used a rewriting script to mostly automatically
replace all occurances of this pattern, and add the
`lib` argument to the package header if it doesn’t
exist yet.

The script in its current form is available at
https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
2021-01-11 10:38:22 +01:00

38 lines
1.3 KiB
Nix

{lib, stdenv, fetchgit, autoreconfHook, halibut}:
let
date = "20200705";
rev = "2a7d4a2";
in
stdenv.mkDerivation {
pname = "agedu";
version = "${date}.${rev}";
# upstream provides tarballs but it seems they disappear after the next version is released
src = fetchgit {
url = "https://git.tartarus.org/simon/agedu.git";
inherit rev;
sha256 = "gRNscl/vhBoZaHFCs9JjDBHDRoEpILJLtiI4YV+K/b4=";
};
nativeBuildInputs = [autoreconfHook halibut];
meta = with lib; {
description = "A Unix utility for tracking down wasted disk space";
longDescription = ''
Most Unix file systems, in their default mode, helpfully record when a
file was last accessed. So if you generated a large amount of data years
ago, forgot to clean it up, and have never used it since, then it ought
in principle to be possible to use those last-access time stamps to tell
the difference between that and a large amount of data you're still
using regularly.
agedu uses this information to tell you which files waste disk space when
you haven't used them since a long time.
'';
homepage = "https://www.chiark.greenend.org.uk/~sgtatham/agedu/";
license = licenses.mit;
maintainers = with maintainers; [ symphorien ];
platforms = platforms.linux;
};
}