Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added ubuntu-font-family #19

Merged
merged 8 commits into from
Jun 23, 2012
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions pkgs/data/fonts/ubuntu-font-family/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{ stdenv, fetchurl, unzip }:

stdenv.mkDerivation rec {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since none of the attributes in the attribute set reference each other, the 'rec' here is unnecessary. But I'm about to suggest a change that will do such recursive referencing, so you might want to wait to remove this.

name = "ubuntu-font-family-0.80";
buildInputs = [unzip];

src = fetchurl {
url = http://font.ubuntu.com/download/ubuntu-font-family-0.80.zip;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since the zipball is named the same as the package, you can do:

url = "http://font.ubuntu.com/download/${name}.zip";

if you keep the 'rec'. This way if the package needs updating you just need to change the name and the hash.

sha256 = "107170099bbc3beae8602b97a5c423525d363106c3c24f787d43e09811298e4c";
};

installPhase =
''
mkdir -p $out/share/fonts/ubuntu
cp *.ttf $out/share/fonts/ubuntu
'';

meta = {
description = "Ubuntu Font Family";
longDescription = "The Ubuntu typeface has been specially
created to complement the Ubuntu tone of voice. It has a
contemporary style and contains characteristics unique to
the Ubuntu brand that convey a precise, reliable and free attitude.";
homepage = http://font.ubuntu.com/;
license = free;
platforms = stdenv.lib.platforms.all;
maintainers = [ stdenv.lib.maintainers.antono ];
};
}
1 change: 1 addition & 0 deletions pkgs/lib/maintainers.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
all = "Nix Committers <nix-commits@lists.science.uu.nl>";
amiddelk = "Arie Middelkoop <amiddelk@gmail.com>";
andres = "Andres Loeh <ksnixos@andres-loeh.de>";
antono = "Antono Vasiljev <self@antono.info>";
astsmtl = "Alexander Tsamutali <astsmtl@yandex.ru>";
bjg = "Brian Gough <bjg@gnu.org>";
bluescreen303 = "Mathijs Kwik <mathijs@bluescreen303.nl>";
Expand Down
2 changes: 2 additions & 0 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6207,6 +6207,8 @@ let

ttf_bitstream_vera = callPackage ../data/fonts/ttf-bitstream-vera { };

ubuntu_font_family = callPackage ../data/fonts/ubuntu-font-family { };

ucsFonts = callPackage ../data/fonts/ucs-fonts { };

unifont = callPackage ../data/fonts/unifont { };
Expand Down