Skip to content

Commit 468db6f

Browse files
authored
Use nixpkgs variants of Sphinx packages (#3227)
This commit replaces manually specified `myst-parser` and `sphinx_rtd_theme` packages with their counterparts already packaged on nixpkgs. With this change, `poetry2nix` is no more used, therefore that is removed as well.
1 parent cdbef3e commit 468db6f

File tree

2 files changed

+2
-118
lines changed

2 files changed

+2
-118
lines changed

flake.lock

-87
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

+2-31
Original file line numberDiff line numberDiff line change
@@ -91,16 +91,6 @@
9191
url = "https://hackage.haskell.org/package/hie-bios-0.11.0/hie-bios-0.11.0.tar.gz";
9292
flake = false;
9393
};
94-
myst-parser = {
95-
url = "github:smunix/MyST-Parser?ref=fix.hls-docutils";
96-
flake = false;
97-
};
98-
# For https://github.com/readthedocs/sphinx_rtd_theme/pull/1185, otherwise lists are broken locally
99-
sphinx_rtd_theme = {
100-
url = "github:readthedocs/sphinx_rtd_theme?rev=34f81daaf52466366c80003db293d50075c1b896";
101-
flake = false;
102-
};
103-
poetry2nix.url = "github:nix-community/poetry2nix/master";
10494
};
10595
outputs =
10696
inputs@{ self, nixpkgs, flake-compat, flake-utils, gitignore, all-cabal-hashes-unpacked, ... }:
@@ -221,7 +211,7 @@
221211
let
222212
pkgs = import nixpkgs {
223213
inherit system;
224-
overlays = [ self.overlays.default inputs.poetry2nix.overlay ];
214+
overlays = [ self.overlays.default ];
225215
config = { allowBroken = true; };
226216
};
227217

@@ -246,26 +236,7 @@
246236
ghc942 = supportedGHCs.ghc942;
247237
ghcDefault = supportedGHCs.default;
248238

249-
# For markdown support
250-
myst-parser = pkgs.poetry2nix.mkPoetryEnv {
251-
projectDir = inputs.myst-parser;
252-
python = pkgs.python39;
253-
overrides = [
254-
pkgs.poetry2nix.defaultPoetryOverrides
255-
];
256-
};
257-
sphinx_rtd_theme = pkgs.poetry2nix.mkPoetryEnv {
258-
projectDir = inputs.sphinx_rtd_theme;
259-
python = pkgs.python39;
260-
overrides = [
261-
pkgs.poetry2nix.defaultPoetryOverrides
262-
(self: super: {
263-
# The RTD theme doesn't work with newer docutils
264-
docutils = pkgs.python3Packages.callPackage ./docutils.nix {};
265-
})
266-
];
267-
};
268-
pythonWithPackages = pkgs.python3.withPackages (ps: [ps.sphinx myst-parser sphinx_rtd_theme ps.pip]);
239+
pythonWithPackages = pkgs.python3.withPackages (ps: [ps.sphinx ps.myst-parser ps.sphinx_rtd_theme ps.pip]);
269240

270241
docs = pkgs.stdenv.mkDerivation {
271242
name = "hls-docs";

0 commit comments

Comments
 (0)