From 4b11cd9d8add9b0fabc225ada3ac4a753ccc3766 Mon Sep 17 00:00:00 2001 From: Minijackson Date: Sat, 4 Mar 2023 17:50:21 +0100 Subject: add flake.lock, use italic for comments in perldoc pygments style --- flake.lock | 78 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ overlay.nix | 6 +++++ 2 files changed, 84 insertions(+) create mode 100644 flake.lock diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..319645f --- /dev/null +++ b/flake.lock @@ -0,0 +1,78 @@ +{ + "nodes": { + "beamertheme-metropolis": { + "flake": false, + "locked": { + "lastModified": 1533142502, + "narHash": "sha256-1HptXntlCUtXwhKuenuVjsj4K3oK5eOsNPZ9+nwSczg=", + "owner": "matze", + "repo": "mtheme", + "rev": "2fa6084b9d34fec9d2d5470eb9a17d0bf712b6c8", + "type": "github" + }, + "original": { + "owner": "matze", + "repo": "mtheme", + "type": "github" + } + }, + "draculaTheme": { + "flake": false, + "locked": { + "lastModified": 1647823152, + "narHash": "sha256-nhuG6QUJgoD2/BtKYrC6OmBSzIQeMNe5NNQqjG6d+Uw=", + "owner": "dracula", + "repo": "pygments", + "rev": "9cf371f24908e2b138cfcf0a87d0d654b4befd8f", + "type": "github" + }, + "original": { + "owner": "dracula", + "repo": "pygments", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1677676435, + "narHash": "sha256-6FxdcmQr5JeZqsQvfinIMr0XcTyTuR7EXX0H3ANShpQ=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "a08d6979dd7c82c4cef0dcc6ac45ab16051c1169", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "pandoc-templates": { + "flake": false, + "locked": { + "lastModified": 1636017162, + "narHash": "sha256-6mnivyy0F3eqiZC6A0z2oSf40JfWS9U3HkKIW5g/NcQ=", + "owner": "minijackson", + "repo": "pandoc-templates", + "rev": "99e04d26dbd1a1056d8664c8cbeb96a06a1dbe11", + "type": "github" + }, + "original": { + "owner": "minijackson", + "repo": "pandoc-templates", + "type": "github" + } + }, + "root": { + "inputs": { + "beamertheme-metropolis": "beamertheme-metropolis", + "draculaTheme": "draculaTheme", + "nixpkgs": "nixpkgs", + "pandoc-templates": "pandoc-templates" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/overlay.nix b/overlay.nix index 85be7b7..b276251 100644 --- a/overlay.nix +++ b/overlay.nix @@ -6,6 +6,7 @@ final: prev: inherit (inputs) pandoc-templates; pygments = prev.python3Packages.pygments.overrideAttrs (oldAttrs: { + # TODO: disable italic for non-normal comments for Perldoc style postPatch = '' cp ${inputs.draculaTheme}/dracula.py pygments/styles/ sed -i \ @@ -17,6 +18,11 @@ final: prev: -e 's/ffff00/ffcd00/' \ -e 's/008400/8fff8b/' \ pygments/styles/inkpot.py + + sed -i \ + -e 's/bg:.\+ //' \ + -e 's/#228B22/italic #228B22/' \ + pygments/styles/perldoc.py ''; }); -- cgit v1.2.3