update build-super-ttc script

This commit is contained in:
Anthony Cicchetti 2023-05-25 09:46:38 -04:00
parent 7081efe4fd
commit 78afc16b0d
2 changed files with 40 additions and 37 deletions

12
flake.lock generated
View file

@ -8,11 +8,11 @@
"pre-commit-hooks": "pre-commit-hooks" "pre-commit-hooks": "pre-commit-hooks"
}, },
"locked": { "locked": {
"lastModified": 1683288106, "lastModified": 1685013540,
"narHash": "sha256-8/yuP6gWLhK8tRCtyqY5QnTq9GF7pCWpZyyZ08lXFwM=", "narHash": "sha256-UM9tPy9fyfXs+knxwk/rCIaNfVC7ggwzbLcY8lkOr+E=",
"owner": "cachix", "owner": "cachix",
"repo": "devenv", "repo": "devenv",
"rev": "c4006ccba1b3e4533de462cee5933e0ccf5f1d6a", "rev": "5ff14a8f2828a2e607a65e2b16650a8cf950515b",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -164,11 +164,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1683207485, "lastModified": 1684936879,
"narHash": "sha256-gs+PHt/y/XQB7S8+YyBLAM8LjgYpPZUVFQBwpFSmJro=", "narHash": "sha256-BOSq/QiX7MDs8tUnAt4+nYTJctgYkzVSNL95qlfMYeM=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "cc45a3f8c98e1c33ca996e3504adefbf660a72d1", "rev": "99fe1b870522d6ee3e692c2b6e663d6868a3fde4",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -5,38 +5,41 @@
devenv.url = "github:cachix/devenv"; devenv.url = "github:cachix/devenv";
}; };
outputs = { self, nixpkgs, devenv, systems, ... } @ inputs: outputs = {
let self,
forEachSystem = nixpkgs.lib.genAttrs (import systems); nixpkgs,
in devenv,
{ systems,
devShells = forEachSystem ...
(system: } @ inputs: let
let forEachSystem = nixpkgs.lib.genAttrs (import systems);
pkgs = nixpkgs.legacyPackages.${system}; in {
in devShells =
{ forEachSystem
default = devenv.lib.mkShell { (system: let
inherit inputs pkgs; pkgs = nixpkgs.legacyPackages.${system};
modules = [ in {
{ default = devenv.lib.mkShell {
# https://devenv.sh/reference/options/ inherit inputs pkgs;
packages = [ pkgs.git pkgs.ttfautohint-nox ]; modules = [
languages.javascript.enable = true; {
# https://devenv.sh/reference/options/
packages = [pkgs.git pkgs.ttfautohint-nox];
languages.javascript.enable = true;
scripts."build-super-ttc".exec = '' scripts."build-super-ttc".exec = ''
git clone --single-branch --depth=1 https://github.com/be5invis/Iosevka git clone --single-branch --depth=1 https://github.com/be5invis/Iosevka || pushd Iosevka && git pull && popd
cp private-build-plans.toml ./Iosevka cp private-build-plans.toml ./Iosevka
cd ./Iosevka cd ./Iosevka
npm install npm install
npm run build -- super-ttc::iosevka-acicchetti npm run build -- super-ttc::iosevka-acicchetti
mv dist/.super-ttc/iosevka-acicchetti.ttc ../iosevka-acicchetti-$(date -I).ttc mv dist/.super-ttc/iosevka-acicchetti.ttc ../iosevka-acicchetti-$(date -I).ttc
''; '';
} }
]; ];
}; };
}); });
}; };
} }