diff options
Diffstat (limited to 'pkgs/data/fonts/powerline-fonts')
-rw-r--r-- | pkgs/data/fonts/powerline-fonts/default.nix | 30 |
1 files changed, 12 insertions, 18 deletions
diff --git a/pkgs/data/fonts/powerline-fonts/default.nix b/pkgs/data/fonts/powerline-fonts/default.nix index c932c7f06c036..c8044905a0887 100644 --- a/pkgs/data/fonts/powerline-fonts/default.nix +++ b/pkgs/data/fonts/powerline-fonts/default.nix @@ -1,30 +1,24 @@ -{ stdenv, fetchzip}: +{ lib, fetchFromGitHub }: -fetchzip { +fetchFromGitHub { name = "powerline-fonts-2018-11-11"; - url = https://github.com/powerline/fonts/archive/e80e3eba9091dac0655a0a77472e10f53e754bb0.zip; + owner = "powerline"; + repo = "fonts"; + rev = "e80e3eba9091dac0655a0a77472e10f53e754bb0"; postFetch = '' - mkdir -p $out/share/fonts/opentype - unzip -j $downloadedFile '*.otf' -d $out/share/fonts/opentype - - mkdir -p $out/share/fonts/truetype - unzip -j $downloadedFile '*.ttf' -d $out/share/fonts/truetype - - mkdir -p $out/share/fonts/bdf - unzip -j $downloadedFile '*/BDF/*.bdf' -d $out/share/fonts/bdf - - mkdir -p $out/share/fonts/pcf - unzip -j $downloadedFile '*/PCF/*.pcf.gz' -d $out/share/fonts/pcf - - mkdir -p $out/share/fonts/psf - unzip -j $downloadedFile '*/PSF/*.psf.gz' -d $out/share/fonts/psf + tar xf $downloadedFile --strip=1 + find . -name '*.otf' -exec install -Dt $out/share/fonts/opentype {} \; + find . -name '*.ttf' -exec install -Dt $out/share/fonts/truetype {} \; + find . -name '*.bdf' -exec install -Dt $out/share/fonts/bdf {} \; + find . -name '*.pcf.gz' -exec install -Dt $out/share/fonts/pcf {} \; + find . -name '*.psf.gz' -exec install -Dt $out/share/fonts/psf {} \; ''; sha256 = "0irifak86gn7hawzgxcy53s22y215mxc2kjncv37h7q44jsqdqww"; - meta = with stdenv.lib; { + meta = with lib; { homepage = https://github.com/powerline/fonts; description = "Patched fonts for Powerline users"; longDescription = '' |