Skip to content

Commit

Permalink
Trac #21513: Package rst2ipynb
Browse files Browse the repository at this point in the history
`rst2ipynb` converts rst source to ipynb worksheet.

- upstream tarball : https://pypi.python.org/packages/59/74/ed45a207317c
8dbfe987db83841ba4d262cfe9fc561fe3180185f82f1e95/rst2ipynb-0.2.1.tar.gz

This package will be used through the straightforward `sage -rst2ipynb`
command, see #21514 You can still test it by hand as follows: install
`pandoc` on your system and if you have a `myfile.rst` do:

{{{
sage -sh
rst2ipynb --kernel='sagemath' myfile.rst -o myfile.ipynb
}}}

URL: https://trac.sagemath.org/21513
Reported by: tmonteil
Ticket author(s): Thierry Monteil, Nicolas M. Thiéry
Reviewer(s): Sébastien Labbé
  • Loading branch information
Release Manager authored and vbraun committed Nov 25, 2016
2 parents c4df8bb + d5d5680 commit 4c9e162
Show file tree
Hide file tree
Showing 6 changed files with 48 additions and 0 deletions.
34 changes: 34 additions & 0 deletions build/pkgs/rst2ipynb/SPKG.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
= rst2ipynb =

== Description ==

The rst2pynb program converts a standalone reStructuredText file to a
Jupyter notebook file.

This is currently achieved by converting to markdown with pandoc and
then to Jupyter notebook using notedown, plus some configuration and
tweaks.

== License ==

BSD 3-Clause License

== Upstream Contact ==

Authors: Scott Sievert and Nicolas M. Thiéry
Home page: https://github.com/nthiery/rst-to-ipynb

== Dependencies ==

* notedown
* pandoc

== Special Update/Build Instructions ==

Fetch tarball from https://pypi.python.org/pypi/rst2ipynb/

As it is written in Haskell, pandoc must be installed from the distro.

The main rationale for having a notedown package in Sage (rather than
just let pip fetch it) is that the version on pipy (1.5.0, 2015-10-07)
is outdated and lacks important features / fixes for us.
4 changes: 4 additions & 0 deletions build/pkgs/rst2ipynb/checksums.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
tarball=rst2ipynb-VERSION.tar.gz
sha1=660df59d66a052a9337517ed55e018307d3549ce
md5=8d85aa294c25ccaf3bb080bc6eb50e59
cksum=1127236178
5 changes: 5 additions & 0 deletions build/pkgs/rst2ipynb/dependencies
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
$(PYTHON) | setuptools pip notedown

----------
All lines of this file are ignored except the first.
It is copied by SAGE_ROOT/build/make/install into SAGE_ROOT/build/make/Makefile.
1 change: 1 addition & 0 deletions build/pkgs/rst2ipynb/package-version.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
0.2.1
3 changes: 3 additions & 0 deletions build/pkgs/rst2ipynb/spkg-install
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/usr/bin/env bash

cd src && $PIP_INSTALL .
1 change: 1 addition & 0 deletions build/pkgs/rst2ipynb/type
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
optional

0 comments on commit 4c9e162

Please sign in to comment.