mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-02 20:03:16 +00:00
342333c0ab
Since https://github.com/NixOS/nixpkgs/pull/48841 was replaced by
https://github.com/NixOS/nixpkgs/pull/54186, this needs to be done
separately.
(cherry picked from commit 33db01e6d9
)
54 lines
1.1 KiB
Nix
54 lines
1.1 KiB
Nix
{ stdenv
|
|
, fetchpatch
|
|
, python
|
|
, buildPythonPackage
|
|
, fetchFromGitHub
|
|
, mathjax
|
|
, twisted
|
|
, flask
|
|
, flask-oldsessions
|
|
, flask-openid
|
|
, flask-autoindex
|
|
, flask-babel
|
|
}:
|
|
|
|
# Has a cyclic dependency with sage (not expressed here) and is not useful outside of sage.
|
|
# Deprecated, hopefully soon to be removed. See
|
|
# https://trac.sagemath.org/ticket/25837
|
|
|
|
buildPythonPackage rec {
|
|
pname = "sagenb";
|
|
version = "1.1.2";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "sagemath";
|
|
repo = "sagenb";
|
|
rev = version;
|
|
sha256 = "0bxvhr03qh2nsjdfc4pyfiqrn9jhp3vf7irsc9gqx0185jlblbxs";
|
|
};
|
|
|
|
propagatedBuildInputs = [
|
|
twisted
|
|
flask
|
|
flask-oldsessions
|
|
flask-openid
|
|
flask-autoindex
|
|
flask-babel
|
|
];
|
|
|
|
# tests depend on sage
|
|
doCheck = false;
|
|
|
|
meta = with stdenv.lib; {
|
|
description = "Sage Notebook";
|
|
license = licenses.gpl3Plus;
|
|
maintainers = with maintainers; [ timokau ];
|
|
};
|
|
|
|
# let sagenb use mathjax
|
|
postInstall = ''
|
|
mkdir -p "$out/${python.sitePackages}/sagenb/data"
|
|
ln -s ${mathjax}/lib/node_modules/mathjax "$out/${python.sitePackages}/sagenb/data/mathjax"
|
|
'';
|
|
}
|