python2.pkgs.ipython: use the proper python2 lexer
Since pygments 2.5 `PythonLexer` refers to python3 [1]. We have to be explicit if we want to use python2. [1] https://pygments.org/docs/changelog/
This commit is contained in:
parent
50c661c447
commit
66675b5650
@ -2,6 +2,7 @@
|
||||
, stdenv
|
||||
, buildPythonPackage
|
||||
, fetchPypi
|
||||
, fetchpatch
|
||||
# Build dependencies
|
||||
, glibcLocales
|
||||
# Test dependencies
|
||||
@ -36,6 +37,15 @@ buildPythonPackage rec {
|
||||
substituteInPlace setup.py --replace "'gnureadline'" " "
|
||||
'';
|
||||
|
||||
patches = [
|
||||
# Use the proper pygments lexer for python2 (https://github.com/ipython/ipython/pull/12095)
|
||||
(fetchpatch {
|
||||
name = "python2-lexer.patch";
|
||||
url = "https://github.com/ipython/ipython/pull/12095/commits/8805293b5e4bce9150cc2ad9c5d6d984849ae447.patch";
|
||||
sha256 = "16p4gl7a49v76w33j39ih7yspy6x2d14p9bh4wdpg9cafhw9nbc0";
|
||||
})
|
||||
];
|
||||
|
||||
buildInputs = [ glibcLocales ];
|
||||
|
||||
checkInputs = [ nose pygments testpath ] ++ lib.optional isPy27 mock;
|
||||
|
Loading…
Reference in New Issue
Block a user