2021-01-25 08:26:54 +00:00
|
|
|
{ lib
|
2019-11-07 17:53:54 +00:00
|
|
|
, fetchurl
|
|
|
|
, symlinkJoin
|
|
|
|
}:
|
|
|
|
|
|
|
|
let
|
2022-03-27 21:01:00 +00:00
|
|
|
version = "14.0";
|
2019-11-07 17:53:54 +00:00
|
|
|
|
|
|
|
fetchData = { file, sha256 }: fetchurl {
|
|
|
|
url = "https://www.unicode.org/Public/emoji/${version}/${file}";
|
|
|
|
inherit sha256;
|
|
|
|
downloadToTemp = true;
|
|
|
|
recursiveHash = true;
|
|
|
|
postFetch = ''
|
|
|
|
installDir="$out/share/unicode/emoji"
|
|
|
|
mkdir -p "$installDir"
|
|
|
|
mv "$downloadedFile" "$installDir/${file}"
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
srcs = {
|
|
|
|
emoji-sequences = fetchData {
|
|
|
|
file = "emoji-sequences.txt";
|
2022-03-27 21:01:00 +00:00
|
|
|
sha256 = "sha256-4helD/0oe+UmNIuVxPx/P0R9V10EY/RccewdeemeGxE=";
|
2019-11-07 17:53:54 +00:00
|
|
|
};
|
|
|
|
emoji-test = fetchData {
|
|
|
|
file = "emoji-test.txt";
|
2022-03-27 21:01:00 +00:00
|
|
|
sha256 = "sha256-DDOVhnFzfvowINzBZ7dGYMZnL4khyRWVzrLL95djsUg=";
|
2019-11-07 17:53:54 +00:00
|
|
|
};
|
|
|
|
emoji-zwj-sequences = fetchData {
|
|
|
|
file = "emoji-zwj-sequences.txt";
|
2022-03-27 21:01:00 +00:00
|
|
|
sha256 = "sha256-owlGLICFkyEsIHz/DUZucxjBmgVO40A69BCJPbIYDA0=";
|
2019-11-07 17:53:54 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
in
|
|
|
|
|
|
|
|
symlinkJoin rec {
|
|
|
|
name = "unicode-emoji-${version}";
|
|
|
|
|
|
|
|
paths = lib.attrValues srcs;
|
|
|
|
|
|
|
|
passthru = srcs;
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2019-11-07 17:53:54 +00:00
|
|
|
description = "Unicode Emoji Data Files";
|
|
|
|
homepage = "https://home.unicode.org/emoji/";
|
2020-03-27 21:15:03 +00:00
|
|
|
license = licenses.unicode-dfs-2016;
|
2019-11-07 17:53:54 +00:00
|
|
|
platforms = platforms.all;
|
|
|
|
};
|
|
|
|
}
|