Skip to content
Merged
Changes from 2 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
8 changes: 4 additions & 4 deletions pkgs/data/fonts/junicode/default.nix
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
{ lib, fetchzip }:

fetchzip {
Comment thread
ivan-timokhin marked this conversation as resolved.
Outdated
name = "junicode-0.7.8";
name = "junicode-1.002";

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

In the spirit of NixOS/rfcs#35:

Suggested change
name = "junicode-1.002";
pname = "junicode";
version = "1.002";

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I just realized that this is using fetchzip, not mkDerivation. I'm not sure if the "name from pname and version" behaviour is implemented here. If it isn't, you additionally need to set

name = "${pname}-${version}";

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Not only doesn't it support ‘name from pname and version’, it actually gives me an error about unexpected argument ‘version’ in fetchurl if I try. So I let-bound them instead (following the example of agave.


url = mirror://sourceforge/junicode/junicode/junicode-0-7-8/junicode-0-7-8.zip;
url = mirror://sourceforge/junicode/junicode/junicode-1.002/junicode-1.002.zip;
Comment thread
ivan-timokhin marked this conversation as resolved.
Outdated

postFetch = ''
mkdir -p $out/share/fonts
unzip -j $downloadedFile \*.ttf -d $out/share/fonts/junicode-ttf
'';

sha256 = "0q4si9pnbif36154sv49kzc7ygivgflv81nzmblpz3b2p77g9956";
sha256 = "1n170gw41lr0zr5958z5cgpg6i1aa7kj7iq9s6gdh1cqq7hhgd08";

meta = {
homepage = http://junicode.sourceforge.net/;
description = "A Unicode font for medievalists";
license = lib.licenses.gpl2Plus;
license = lib.licenses.ofl;
};
}