From 4556ab321a2c232453d99e58a336e17221c5d1dd Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Tue, 3 Nov 2020 15:05:47 -0300 Subject: Move other Nix files to nix/ --- _config.yml | 11 +- default.nix | 4 +- gemset.nix | 300 ----------------------------------------------------- nix/gemset.nix | 300 +++++++++++++++++++++++++++++++++++++++++++++++++++++ nix/utils-i18n.nix | 57 ++++++++++ utils-i18n.nix | 57 ---------- 6 files changed, 363 insertions(+), 366 deletions(-) delete mode 100644 gemset.nix create mode 100644 nix/gemset.nix create mode 100644 nix/utils-i18n.nix delete mode 100644 utils-i18n.nix diff --git a/_config.yml b/_config.yml index 01fccb9..b5fb265 100644 --- a/_config.yml +++ b/_config.yml @@ -19,20 +19,17 @@ kramdown: exclude: - Gemfile - Gemfile.lock - - gemset.nix - README - TODOs.org - LICENSE - default.nix - - utils.nix - shell.nix - - spelling/ + - nix/ - scripts/ - - result + - result* - templates/ - - drafts/ - - description - - result + - metadata.json + - tests.sh - images/graphviz/ collections: diff --git a/default.nix b/default.nix index c601e0d..4f992aa 100644 --- a/default.nix +++ b/default.nix @@ -2,14 +2,14 @@ let niv-sources = import ./nix/sources.nix; pkgs = import niv-sources.nixpkgs { }; src = pkgs.nix-gitignore.gitignoreSource [ "!.git" ] ./.; - utils-i18n = pkgs.callPackage ./utils-i18n.nix { }; + utils-i18n = pkgs.callPackage ./nix/utils-i18n.nix { }; pkgs-next = pkgs.callPackage ./nix/nixpkgs-next.nix { }; jekyllEnv = pkgs.bundlerEnv { name = "jekyll-env"; gemfile = ./Gemfile; lockfile = ./Gemfile.lock; - gemset = ./gemset.nix; + gemset = ./nix/gemset.nix; }; projectBuildInputs = with pkgs; [ diff --git a/gemset.nix b/gemset.nix deleted file mode 100644 index b13c463..0000000 --- a/gemset.nix +++ /dev/null @@ -1,300 +0,0 @@ -{ - addressable = { - dependencies = [ "public_suffix" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "1fvchp2rhp2rmigx7qglf69xvjqvzq7x0g49naliw29r2bz656sy"; - type = "gem"; - }; - version = "2.7.0"; - }; - colorator = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "0f7wvpam948cglrciyqd798gdc6z3cfijciavd0dfixgaypmvy72"; - type = "gem"; - }; - version = "1.1.0"; - }; - concurrent-ruby = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "1vnxrbhi7cq3p4y2v9iwd10v1c7l15is4var14hwnb2jip4fyjzz"; - type = "gem"; - }; - version = "1.1.7"; - }; - em-websocket = { - dependencies = [ "eventmachine" "http_parser.rb" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "1bsw8vjz0z267j40nhbmrvfz7dvacq4p0pagvyp17jif6mj6v7n3"; - type = "gem"; - }; - version = "0.5.1"; - }; - eventmachine = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "0wh9aqb0skz80fhfn66lbpr4f86ya2z5rx6gm5xlfhd05bj1ch4r"; - type = "gem"; - }; - version = "1.2.7"; - }; - ffi = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "12lpwaw82bb0rm9f52v1498bpba8aj2l2q359mkwbxsswhpga5af"; - type = "gem"; - }; - version = "1.13.1"; - }; - forwardable-extended = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "15zcqfxfvsnprwm8agia85x64vjzr2w0xn9vxfnxzgcv8s699v0v"; - type = "gem"; - }; - version = "2.6.0"; - }; - "http_parser.rb" = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "15nidriy0v5yqfjsgsra51wmknxci2n2grliz78sf9pga3n0l7gi"; - type = "gem"; - }; - version = "0.6.0"; - }; - i18n = { - dependencies = [ "concurrent-ruby" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "153sx77p16vawrs4qpkv7qlzf9v5fks4g7xqcj1dwk40i6g7rfzk"; - type = "gem"; - }; - version = "1.8.5"; - }; - jekyll = { - dependencies = [ - "addressable" - "colorator" - "em-websocket" - "i18n" - "jekyll-sass-converter" - "jekyll-watch" - "kramdown" - "kramdown-parser-gfm" - "liquid" - "mercenary" - "pathutil" - "rouge" - "safe_yaml" - "terminal-table" - ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "192k1ggw99slpqpxb4xamcvcm2pdahgnmygl746hmkrar0i3xa5r"; - type = "gem"; - }; - version = "4.1.1"; - }; - jekyll-sass-converter = { - dependencies = [ "sassc" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "04ncr44wrilz26ayqwlg7379yjnkb29mvx4j04i62b7czmdrc9dv"; - type = "gem"; - }; - version = "2.1.0"; - }; - jekyll-watch = { - dependencies = [ "listen" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "1qd7hy1kl87fl7l0frw5qbn22x7ayfzlv9a5ca1m59g0ym1ysi5w"; - type = "gem"; - }; - version = "2.2.1"; - }; - kramdown = { - dependencies = [ "rexml" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "1vmw752c26ny2jwl0npn0gbyqwgz4hdmlpxnsld9qi9xhk5b1qh7"; - type = "gem"; - }; - version = "2.3.0"; - }; - kramdown-parser-gfm = { - dependencies = [ "kramdown" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "0a8pb3v951f4x7h968rqfsa19c8arz21zw1vaj42jza22rap8fgv"; - type = "gem"; - }; - version = "1.1.0"; - }; - liquid = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "0zhg5ha8zy8zw9qr3fl4wgk4r5940n4128xm2pn4shpbzdbsj5by"; - type = "gem"; - }; - version = "4.0.3"; - }; - listen = { - dependencies = [ "rb-fsevent" "rb-inotify" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "1w923wmdi3gyiky0asqdw5dnh3gcjs2xyn82ajvjfjwh6sn0clgi"; - type = "gem"; - }; - version = "3.2.1"; - }; - mercenary = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "0f2i827w4lmsizrxixsrv2ssa3gk1b7lmqh8brk8ijmdb551wnmj"; - type = "gem"; - }; - version = "0.4.0"; - }; - pathutil = { - dependencies = [ "forwardable-extended" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "12fm93ljw9fbxmv2krki5k5wkvr7560qy8p4spvb9jiiaqv78fz4"; - type = "gem"; - }; - version = "0.16.2"; - }; - public_suffix = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "0vywld400fzi17cszwrchrzcqys4qm6sshbv73wy5mwcixmrgg7g"; - type = "gem"; - }; - version = "4.0.5"; - }; - rb-fsevent = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "1k9bsj7ni0g2fd7scyyy1sk9dy2pg9akniahab0iznvjmhn54h87"; - type = "gem"; - }; - version = "0.10.4"; - }; - rb-inotify = { - dependencies = [ "ffi" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "1jm76h8f8hji38z3ggf4bzi8vps6p7sagxn3ab57qc0xyga64005"; - type = "gem"; - }; - version = "0.10.1"; - }; - rexml = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "1mkvkcw9fhpaizrhca0pdgjcrbns48rlz4g6lavl5gjjq3rk2sq3"; - type = "gem"; - }; - version = "3.2.4"; - }; - rouge = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "1wcz7i009wdbymlfsamagqi18m6ih8j60bii0k18f21g70r72i0m"; - type = "gem"; - }; - version = "3.22.0"; - }; - safe_yaml = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "0j7qv63p0vqcd838i2iy2f76c3dgwzkiz1d1xkg7n0pbnxj2vb56"; - type = "gem"; - }; - version = "1.0.5"; - }; - sassc = { - dependencies = [ "ffi" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "0gpqv48xhl8mb8qqhcifcp0pixn206a7imc07g48armklfqa4q2c"; - type = "gem"; - }; - version = "2.4.0"; - }; - terminal-table = { - dependencies = [ "unicode-display_width" ]; - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "1512cngw35hsmhvw4c05rscihc59mnj09m249sm9p3pik831ydqk"; - type = "gem"; - }; - version = "1.8.0"; - }; - unicode-display_width = { - groups = [ "default" ]; - platforms = [ ]; - source = { - remotes = [ "https://rubygems.org" ]; - sha256 = "06i3id27s60141x6fdnjn5rar1cywdwy64ilc59cz937303q3mna"; - type = "gem"; - }; - version = "1.7.0"; - }; -} diff --git a/nix/gemset.nix b/nix/gemset.nix new file mode 100644 index 0000000..b13c463 --- /dev/null +++ b/nix/gemset.nix @@ -0,0 +1,300 @@ +{ + addressable = { + dependencies = [ "public_suffix" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "1fvchp2rhp2rmigx7qglf69xvjqvzq7x0g49naliw29r2bz656sy"; + type = "gem"; + }; + version = "2.7.0"; + }; + colorator = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "0f7wvpam948cglrciyqd798gdc6z3cfijciavd0dfixgaypmvy72"; + type = "gem"; + }; + version = "1.1.0"; + }; + concurrent-ruby = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "1vnxrbhi7cq3p4y2v9iwd10v1c7l15is4var14hwnb2jip4fyjzz"; + type = "gem"; + }; + version = "1.1.7"; + }; + em-websocket = { + dependencies = [ "eventmachine" "http_parser.rb" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "1bsw8vjz0z267j40nhbmrvfz7dvacq4p0pagvyp17jif6mj6v7n3"; + type = "gem"; + }; + version = "0.5.1"; + }; + eventmachine = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "0wh9aqb0skz80fhfn66lbpr4f86ya2z5rx6gm5xlfhd05bj1ch4r"; + type = "gem"; + }; + version = "1.2.7"; + }; + ffi = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "12lpwaw82bb0rm9f52v1498bpba8aj2l2q359mkwbxsswhpga5af"; + type = "gem"; + }; + version = "1.13.1"; + }; + forwardable-extended = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "15zcqfxfvsnprwm8agia85x64vjzr2w0xn9vxfnxzgcv8s699v0v"; + type = "gem"; + }; + version = "2.6.0"; + }; + "http_parser.rb" = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "15nidriy0v5yqfjsgsra51wmknxci2n2grliz78sf9pga3n0l7gi"; + type = "gem"; + }; + version = "0.6.0"; + }; + i18n = { + dependencies = [ "concurrent-ruby" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "153sx77p16vawrs4qpkv7qlzf9v5fks4g7xqcj1dwk40i6g7rfzk"; + type = "gem"; + }; + version = "1.8.5"; + }; + jekyll = { + dependencies = [ + "addressable" + "colorator" + "em-websocket" + "i18n" + "jekyll-sass-converter" + "jekyll-watch" + "kramdown" + "kramdown-parser-gfm" + "liquid" + "mercenary" + "pathutil" + "rouge" + "safe_yaml" + "terminal-table" + ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "192k1ggw99slpqpxb4xamcvcm2pdahgnmygl746hmkrar0i3xa5r"; + type = "gem"; + }; + version = "4.1.1"; + }; + jekyll-sass-converter = { + dependencies = [ "sassc" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "04ncr44wrilz26ayqwlg7379yjnkb29mvx4j04i62b7czmdrc9dv"; + type = "gem"; + }; + version = "2.1.0"; + }; + jekyll-watch = { + dependencies = [ "listen" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "1qd7hy1kl87fl7l0frw5qbn22x7ayfzlv9a5ca1m59g0ym1ysi5w"; + type = "gem"; + }; + version = "2.2.1"; + }; + kramdown = { + dependencies = [ "rexml" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "1vmw752c26ny2jwl0npn0gbyqwgz4hdmlpxnsld9qi9xhk5b1qh7"; + type = "gem"; + }; + version = "2.3.0"; + }; + kramdown-parser-gfm = { + dependencies = [ "kramdown" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "0a8pb3v951f4x7h968rqfsa19c8arz21zw1vaj42jza22rap8fgv"; + type = "gem"; + }; + version = "1.1.0"; + }; + liquid = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "0zhg5ha8zy8zw9qr3fl4wgk4r5940n4128xm2pn4shpbzdbsj5by"; + type = "gem"; + }; + version = "4.0.3"; + }; + listen = { + dependencies = [ "rb-fsevent" "rb-inotify" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "1w923wmdi3gyiky0asqdw5dnh3gcjs2xyn82ajvjfjwh6sn0clgi"; + type = "gem"; + }; + version = "3.2.1"; + }; + mercenary = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "0f2i827w4lmsizrxixsrv2ssa3gk1b7lmqh8brk8ijmdb551wnmj"; + type = "gem"; + }; + version = "0.4.0"; + }; + pathutil = { + dependencies = [ "forwardable-extended" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "12fm93ljw9fbxmv2krki5k5wkvr7560qy8p4spvb9jiiaqv78fz4"; + type = "gem"; + }; + version = "0.16.2"; + }; + public_suffix = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "0vywld400fzi17cszwrchrzcqys4qm6sshbv73wy5mwcixmrgg7g"; + type = "gem"; + }; + version = "4.0.5"; + }; + rb-fsevent = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "1k9bsj7ni0g2fd7scyyy1sk9dy2pg9akniahab0iznvjmhn54h87"; + type = "gem"; + }; + version = "0.10.4"; + }; + rb-inotify = { + dependencies = [ "ffi" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "1jm76h8f8hji38z3ggf4bzi8vps6p7sagxn3ab57qc0xyga64005"; + type = "gem"; + }; + version = "0.10.1"; + }; + rexml = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "1mkvkcw9fhpaizrhca0pdgjcrbns48rlz4g6lavl5gjjq3rk2sq3"; + type = "gem"; + }; + version = "3.2.4"; + }; + rouge = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "1wcz7i009wdbymlfsamagqi18m6ih8j60bii0k18f21g70r72i0m"; + type = "gem"; + }; + version = "3.22.0"; + }; + safe_yaml = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "0j7qv63p0vqcd838i2iy2f76c3dgwzkiz1d1xkg7n0pbnxj2vb56"; + type = "gem"; + }; + version = "1.0.5"; + }; + sassc = { + dependencies = [ "ffi" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "0gpqv48xhl8mb8qqhcifcp0pixn206a7imc07g48armklfqa4q2c"; + type = "gem"; + }; + version = "2.4.0"; + }; + terminal-table = { + dependencies = [ "unicode-display_width" ]; + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "1512cngw35hsmhvw4c05rscihc59mnj09m249sm9p3pik831ydqk"; + type = "gem"; + }; + version = "1.8.0"; + }; + unicode-display_width = { + groups = [ "default" ]; + platforms = [ ]; + source = { + remotes = [ "https://rubygems.org" ]; + sha256 = "06i3id27s60141x6fdnjn5rar1cywdwy64ilc59cz937303q3mna"; + type = "gem"; + }; + version = "1.7.0"; + }; +} diff --git a/nix/utils-i18n.nix b/nix/utils-i18n.nix new file mode 100644 index 0000000..95ae312 --- /dev/null +++ b/nix/utils-i18n.nix @@ -0,0 +1,57 @@ +{ pkgs }: rec { + sphinx-intl = with pkgs.python3.pkgs; + buildPythonPackage rec { + pname = "sphinx-intl"; + version = "2.0.1"; + src = fetchPypi { + inherit pname version; + sha256 = "1d1q0sanjp4nkfvhsxi75zf3xjyyi8nzxvl3v7l0jy9ld70nwnmj"; + }; + propagatedBuildInputs = with pkgs.python3Packages; [ Babel click sphinx ]; + }; + dicts = rec { + mkDict = let + prefix = + "https://raw.githubusercontent.com/wooorm/dictionaries/61016e00e276f9bf5e52cbc6c02a45f2e49b2c7e/dictionaries"; + in { lang, dicSHA256, affSHA256 }: + let + dic = builtins.fetchurl { + url = "${prefix}/${lang}/index.dic"; + sha256 = dicSHA256; + }; + aff = builtins.fetchurl { + url = "${prefix}/${lang}/index.aff"; + sha256 = affSHA256; + }; + in pkgs.stdenv.mkDerivation { + name = "website-dict-${lang}"; + builder = builtins.toFile "builder.sh" '' + source $stdenv/setup + install -dm755 $out/share/hunspell + install -m644 ${dic} $out/share/hunspell/${lang}.dic + install -m644 ${aff} $out/share/hunspell/${lang}.aff + runHook postInstall + ''; + }; + en = mkDict { + lang = "en"; + dicSHA256 = "1k4660ccwwpwac0rc7b8ih3vd24kxgvljkrakv2l1f72yfpw3bp2"; + affSHA256 = "0yvc2fhc03y0y1gwjyb20ifcrxnzm3ama1fri9r5gna092fz3qca"; + }; + pt = mkDict { + lang = "pt"; + dicSHA256 = "1z0kfxv8m361xhp4zwdlsn2ib8q3rnljj0b2s4482alyxpd00h9x"; + affSHA256 = "1ssj1g7qwh0lv3ajzvchwsfr7cgzrlqms28m1j3gm1y2avi50qhw"; + }; + fr = mkDict { + lang = "fr"; + dicSHA256 = "10p6jlk9j117mjd1z3dp3vfszcvxqha11kfvksqhvrq4ld9xwzbn"; + affSHA256 = "0d6k608h7gm1za3vdq1fhlwqzz2zxg1z0bx1bfvi0spg4a2mn09p"; + }; + eo = mkDict { + lang = "eo"; + dicSHA256 = "1hbs8f67kq953llcx8pm0rwi2ln2y693pva952fb9mjc4l99ic3m"; + affSHA256 = "198jaiab98xks5srizi3ww7sg5biqhjl7acjhrsrmcycp8jvns56"; + }; + }; +} diff --git a/utils-i18n.nix b/utils-i18n.nix deleted file mode 100644 index 95ae312..0000000 --- a/utils-i18n.nix +++ /dev/null @@ -1,57 +0,0 @@ -{ pkgs }: rec { - sphinx-intl = with pkgs.python3.pkgs; - buildPythonPackage rec { - pname = "sphinx-intl"; - version = "2.0.1"; - src = fetchPypi { - inherit pname version; - sha256 = "1d1q0sanjp4nkfvhsxi75zf3xjyyi8nzxvl3v7l0jy9ld70nwnmj"; - }; - propagatedBuildInputs = with pkgs.python3Packages; [ Babel click sphinx ]; - }; - dicts = rec { - mkDict = let - prefix = - "https://raw.githubusercontent.com/wooorm/dictionaries/61016e00e276f9bf5e52cbc6c02a45f2e49b2c7e/dictionaries"; - in { lang, dicSHA256, affSHA256 }: - let - dic = builtins.fetchurl { - url = "${prefix}/${lang}/index.dic"; - sha256 = dicSHA256; - }; - aff = builtins.fetchurl { - url = "${prefix}/${lang}/index.aff"; - sha256 = affSHA256; - }; - in pkgs.stdenv.mkDerivation { - name = "website-dict-${lang}"; - builder = builtins.toFile "builder.sh" '' - source $stdenv/setup - install -dm755 $out/share/hunspell - install -m644 ${dic} $out/share/hunspell/${lang}.dic - install -m644 ${aff} $out/share/hunspell/${lang}.aff - runHook postInstall - ''; - }; - en = mkDict { - lang = "en"; - dicSHA256 = "1k4660ccwwpwac0rc7b8ih3vd24kxgvljkrakv2l1f72yfpw3bp2"; - affSHA256 = "0yvc2fhc03y0y1gwjyb20ifcrxnzm3ama1fri9r5gna092fz3qca"; - }; - pt = mkDict { - lang = "pt"; - dicSHA256 = "1z0kfxv8m361xhp4zwdlsn2ib8q3rnljj0b2s4482alyxpd00h9x"; - affSHA256 = "1ssj1g7qwh0lv3ajzvchwsfr7cgzrlqms28m1j3gm1y2avi50qhw"; - }; - fr = mkDict { - lang = "fr"; - dicSHA256 = "10p6jlk9j117mjd1z3dp3vfszcvxqha11kfvksqhvrq4ld9xwzbn"; - affSHA256 = "0d6k608h7gm1za3vdq1fhlwqzz2zxg1z0bx1bfvi0spg4a2mn09p"; - }; - eo = mkDict { - lang = "eo"; - dicSHA256 = "1hbs8f67kq953llcx8pm0rwi2ln2y693pva952fb9mjc4l99ic3m"; - affSHA256 = "198jaiab98xks5srizi3ww7sg5biqhjl7acjhrsrmcycp8jvns56"; - }; - }; -} -- cgit v1.2.3