Merge pull request #272535 from atorres1985-contrib/advcpmv

advcpmv: new package

authored by Peder Bergebakken Sundt and committed by GitHub 6d20002d 9575c3e3

+62
+62
pkgs/by-name/ad/advcpmv/package.nix
···
··· 1 + { coreutils 2 + , fetchFromGitHub 3 + }: 4 + 5 + let 6 + advcpmv-data = { 7 + pname = "advcpmv"; 8 + patch-version = "0.9"; 9 + coreutils-version = "9.4"; 10 + version = "${advcpmv-data.patch-version}-${advcpmv-data.coreutils-version}"; 11 + src = fetchFromGitHub { 12 + owner = "jarun"; 13 + repo = "advcpmv"; 14 + rev = "a1f8b505e691737db2f7f2b96275802c45f65c59"; 15 + hash = "sha256-IHfMu6PyGRPc87J/hbxMUdosmLq13K0oWa5fPLWKOvo="; 16 + }; 17 + patch-file = advcpmv-data.src + "/advcpmv-${advcpmv-data.version}.patch"; 18 + }; 19 + coreutilsNoSingleBinary = coreutils.override { singleBinary = false; }; 20 + in 21 + assert (advcpmv-data.coreutils-version == coreutils.version); 22 + coreutilsNoSingleBinary.overrideAttrs (old: { 23 + inherit (advcpmv-data) pname version; 24 + 25 + patches = (old.patches or [ ]) ++ [ 26 + advcpmv-data.patch-file 27 + ]; 28 + 29 + outputs = [ "out" ]; # Since we don't need info files 30 + 31 + configureFlags = (old.configureFlags or [ ]) ++ [ 32 + # To not conflict with regular coreutils 33 + "--program-prefix=adv" 34 + ]; 35 + 36 + # Only cpg and mvg are desired, the others are not touched and therefore can 37 + # be removed. Equally, the info directory is removed. 38 + postFixup = (old.postFixup or "") + '' 39 + rm -rf $out/share/info 40 + pushd $out/bin 41 + mv advcp cpg 42 + mv advmv mvg 43 + rm adv* 44 + mv cpg advcp 45 + mv mvg advmv 46 + ln -s advcp cpg 47 + ln -s advcp acp 48 + ln -s advmv mvg 49 + ln -s advmv amv 50 + popd 51 + ''; 52 + 53 + meta = old.meta // { 54 + homepage = "https://github.com/jarun/advcpmv"; 55 + description = "Patched cp and mv from Coreutils that provides progress bars"; 56 + longDescription = '' 57 + Advanced Copy is a mod for the GNU cp and GNU mv tools which adds a 58 + progress bar and provides some info on what's going on. It was written by 59 + Florian Zwicke and released under the GPL. 60 + ''; 61 + }; 62 + })