lol
fork

Configure Feed

Select the types of activity you want to include in your feed.

at 17.09-beta 29 lines 978 B view raw
1{ stdenv, lib, bower2nix, cacert }: 2let 3 bowerVersion = version: 4 let 5 components = lib.splitString "#" version; 6 hash = lib.last components; 7 ver = if builtins.length components == 1 then version else hash; 8 in ver; 9 10 bowerName = name: lib.replaceStrings ["/"] ["-"] name; 11 12 fetchbower = name: version: target: outputHash: stdenv.mkDerivation { 13 name = "${bowerName name}-${bowerVersion version}"; 14 SSL_CERT_FILE = "${cacert}/etc/ssl/certs/ca-bundle.crt"; 15 buildCommand = '' 16 fetch-bower --quiet --out=$PWD/out "${name}" "${target}" "${version}" 17 # In some cases, the result of fetchBower is different depending 18 # on the output directory (e.g. if the bower package contains 19 # symlinks). So use a local output directory before copying to 20 # $out. 21 cp -R out $out 22 ''; 23 outputHashMode = "recursive"; 24 outputHashAlgo = "sha256"; 25 inherit outputHash; 26 buildInputs = [ bower2nix ]; 27 }; 28 29in fetchbower