commit 96a1e74022d44606a9df39b532aaf9be29e96f26 Author: Evie Litherland-Smith Date: Sun Mar 3 20:45:29 2024 +0000 Initial commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b2be92b --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +result diff --git a/custom-build-plan.nix b/custom-build-plan.nix new file mode 100644 index 0000000..cdf103a --- /dev/null +++ b/custom-build-plan.nix @@ -0,0 +1,63 @@ +{ + noCvSs = true; + exportGlyphNames = false; + ligations.inherits = "dlig"; + weights = { + Regular = { + shape = 400; + menu = 400; + css = 400; + }; + Bold = { + shape = 700; + menu = 700; + css = 700; + }; + }; + variants.design = { + capital-g = "toothless-corner-serifless-hooked"; + capital-j = "serifed-both-sides"; + capital-q = "crossing"; + capital-r = "curly-serifless"; + e = "rounded"; + f = "tailed"; + g = "double-storey-open"; + i = "tailed-serifed"; + j = "serifed"; + k = "cursive-serifless"; + l = "tailed-serifed"; + q = "diagonal-tailed-serifless"; + y = "cursive-serifless"; + z = "straight-serifless-with-horizontal-crossbar"; + lower-delta = "flat-top"; + lower-lambda = "tailed-turn"; + lower-xi = "flat-top"; + lower-chi = "semi-chancery-straight"; + zero = "tall-slashed"; + one = "no-base"; + two = "straight-neck"; + three = "flat-top"; + four = "semi-open"; + five = "oblique-arched"; + six = "open-contour"; + seven = "bend-serifless-crossbar"; + eight = "two-circles"; + nine = "open-contour"; + asterisk = "hex-low"; + underscore = "high"; + caret = "high"; + paren = "normal"; + brace = "straight"; + number-sign = "slanted"; + ampersand = "closed"; + at = "fourfold"; + percent = "dots"; + question = "corner"; + lig-ltgteq = "flat"; + lig-neq = "more-slanted"; + lig-equal-chain = "without-notch"; + lig-hyphen-chain = "without-notch"; + lig-double-arrow-bar = "without-notch"; + lig-single-arrow-bar = "without-notch"; + }; +} diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..9dd6bad --- /dev/null +++ b/flake.lock @@ -0,0 +1,27 @@ +{ + "nodes": { + "nixpkgs": { + "locked": { + "lastModified": 1709237383, + "narHash": "sha256-cy6ArO4k5qTx+l5o+0mL9f5fa86tYUX3ozE1S+Txlds=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "1536926ef5621b09bba54035ae2bb6d806d72ac8", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "nixpkgs": "nixpkgs" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..9bfb7ba --- /dev/null +++ b/flake.nix @@ -0,0 +1,62 @@ +{ + description = "My customised build of Iosevka font"; + + nixConfig = { + extra-substituters = ["https://nix.xenia.me.uk"]; + extra-trusted-public-keys = ["nix.xenia.me.uk:VaQu+8hshk7aSbW3z91pgkKbYeAcO3Q0AomqP8RaaLc="]; + }; + + inputs = { + nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable"; + }; + + outputs = { + self, + nixpkgs, + }: let + system = "x86_64-linux"; + pkgs = import nixpkgs {inherit system;}; + customBuildPlan = import ./custom-build-plan.nix; + in { + packages.${system} = { + iosevka-custom-aile = pkgs.iosevka.override { + set = "aile"; + privateBuildPlan = { + inherit (customBuildPlan) noCvSs exportGlyphNames variants weights; + family = "Iosevka Custom Aile"; + spacing = "quasi-proportional"; + serifs = "sans"; + }; + }; + iosevka-custom-etoile = pkgs.iosevka.override { + set = "etoile"; + privateBuildPlan = { + inherit (customBuildPlan) noCvSs exportGlyphNames variants weights; + family = "Iosevka Custom Etoile"; + spacing = "quasi-proportional"; + serifs = "slab"; + }; + }; + iosevka-custom-nerdfont = let + monospace = pkgs.iosevka.override { + set = "custom"; + privateBuildPlan = { + inherit (customBuildPlan) noCvSs exportGlyphNames variants weights; + family = "Iosevka Custom"; + spacing = "normal"; + serifs = "sans"; + }; + }; + in + pkgs.stdenv.mkDerivation { + name = "${monospace.name}-nerd-font-patched"; + src = monospace; + nativeBuildInputs = [pkgs.nerd-font-patcher]; + buildPhase = '' + find \( -name \*.ttf -o -name \*.otf \) -execdir nerd-font-patcher -c {} \; + ''; + installPhase = "cp -a . $out"; + }; + }; + }; +}