anchor.diff:      patchShebangs $out/bin
     '';
   
  +  pythonImportsCheck = [ "pelican" ];
  +
     meta = with lib; {
  -    description = "A tool to generate a static blog from reStructuredText or Markdown input files";
  +    description = "Static site generator that requires no database or server-side logic";
       homepage = "http://getpelican.com/";
       license = licenses.agpl3;
       maintainers = with maintainers; [ offline prikhi ];
  
positive.code:   ];
  
    propagatedBuildInputs = [
      jinja2 pygments docutils pytz unidecode six python-dateutil feedgenerator
      blinker pillow beautifulsoup4 markupsafe lxml
    ];
  
    checkInputs = [
      nose
      pandoc
    ];
  
    postPatch= ''
      substituteInPlace pelican/tests/test_pelican.py \
        --replace "'git'" "'${git}/bin/git'"
    '';
  
    LC_ALL="en_US.UTF-8";
  
    # We only want to patch shebangs in /bin, and not those
    # of the project scripts that are created by Pelican.
  
negative.code: { lib
  , beautifulsoup4
  , blinker
  , buildPythonPackage
  , docutils
  , feedgenerator
  , fetchFromGitHub
  , git
  , glibcLocales
  , isPy27
  , jinja2
  , lxml
  , markdown
  , markupsafe
  , mock
  , pytestCheckHook
  , pandoc
  , pillow
  , pygments
  , python-dateutil
  , pythonOlder
  , pytz
  , rich
  , pytest-xdist
  , six
  , typogrify
  , unidecode
  }:
  
  buildPythonPackage rec {
    pname = "pelican";
    version = "4.6.0";
    disabled = pythonOlder "3.6";
  
    src = fetchFromGitHub {
      owner = "getpelican";
      repo = pname;
      rev = version;
      sha256 = "0xrz0cmjyaylr81rmy5i3qbp4ms1iwh0gpb07q1dwljffb8xzbhr";
      # Remove unicode file names which leads to different checksums on HFS+
      # vs. other filesystems because of unicode normalisation.
      extraPostFetch = ''
        rm -r $out/pelican/tests/output/custom_locale/posts
      '';
    };
  
    buildInputs = [
      glibcLocales
  