Skip to content

Commit

Permalink
Move to mistletoe-ebp dependency (#107)
Browse files Browse the repository at this point in the history
* Move pandas_sphinx_theme requirement to separate file

Its current form is not accepted by pypi (awaiting pypi release of this package)

* Add PyPi distribution and documentation

* bump version
  • Loading branch information
chrisjsewell committed Mar 5, 2020
1 parent fb83d74 commit 6135ba8
Show file tree
Hide file tree
Showing 8 changed files with 42 additions and 28 deletions.
4 changes: 3 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@ jobs:
- restore_cache:
keys:
- cache-pip
- run: pip install --user -e .[sphinx,rtd]
- run: |
pip install --user -e .[sphinx,rtd]
pip install -r docs/requirements.txt
- save_cache:
key: cache-pip
paths:
Expand Down
1 change: 1 addition & 0 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@ python:
extra_requirements:
- sphinx
- rtd
- requirements: docs/requirments.txt
13 changes: 12 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ matrix:
- python: 3.6
env: TEST_TYPE="pytest"
- python: 3.7
env: TEST_TYPE="pytest"
env: TEST_TYPE="pytest" PYPI_DEPLOY=true
- python: 3.7
env: TEST_TYPE="pre-commit"
install:
Expand Down Expand Up @@ -37,3 +37,14 @@ after_success:
if [[ "$TEST_TYPE" == "pytest" ]]; then
coveralls
fi
deploy:
- provider: pypi
distributions: "sdist bdist_wheel"
user: cjsewell
password:
secure: XDaPRuCORFOvwXUfP6S5QOsFOpQmQiURGA603Rs3WkY0Y4up1uQjDWu2wUCh4cNPM5ITMXMFrRCWCFh289LM21c5pzExvx7RpsXfHol6F0hMGxjwmeU2aRltaVCa/zvevdBmgTa0aOMhOGmiLnSHxSAXYUHxkkHG4GmypsAshWNzJGSzSPBwt6YBkqXkeeJYC0S+t8tFEDjtEwn6E3Iy49L25+mI5ip8N6JRgAgR6umTCfKcCMBuyBii+/VDGKGsM4bdiDnXiDYWn0l9hzzSMr1xeiYtXB56N+6eRgm2oprRNnX4widbq3UJ5tp5/p3R7xXBi7NTz82d2vncNjk9Q3y35AyNb08Y2jJSsAw5CcWjQITvxMsHjhLibvrn/skkLgtE005ItNn4IFceH/y6HgmBn1yrA2z9bxfB5VLmsl4UqXYvn7Bd0l8C4IIbhsxtvH/yOtJ0sXQI3HTZVepJcrf8mAGfJVdnd9eqtMfXIr+6vlRqJByMK8f7drpdfWynC8bzfFrNIh/OHKoZzvEk7o6cDCj91vPcpxygecHvPDf0Tx/vdOFwEF8LTXNWVPjTHJMzurw946vpArCoAC1T8uwF+5fiu/ZcEfudKKincS6K9/2aFzgpoKOdbKP9/1h3hRjjPKc8HqTt9jziwuOl//KS0DJS3BSZZvFyaBI2p/Y=
on:
branch: master
tags: true
condition: $PYPI_DEPLOY = true
28 changes: 21 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,18 @@
# MyST-Parser

[![Build Status](https://travis-ci.org/ExecutableBookProject/MyST-Parser.svg?branch=master)](https://travis-ci.org/ExecutableBookProject/MyST-Parser)
[![Coverage Status](https://coveralls.io/repos/github/ExecutableBookProject/MyST-Parser/badge.svg?branch=master)](https://coveralls.io/github/ExecutableBookProject/MyST-Parser?branch=master)
[![Documentation Status](https://readthedocs.org/projects/myst-parser/badge/?version=latest)](https://myst-parser.readthedocs.io/en/latest/?badge=latest)
[![CI Status][travis-badge]][travis-link]
[![Coverage][coveralls-badge]][coveralls-link]
[![Documentation Status][rtd-badge]][rtd-link]
[![Code style: black][black-badge]][black-link]
[![PyPI][pypi-badge]][pypi-link]
<!-- [![Conda][conda-badge]][conda-link] -->

An extended commonmark compliant parser, with bridges to docutils & sphinx.

## Usage

```bash
pip install -e "git+https://github.com/ExecutableBookProject/MyST-Parser.git#egg=myst-parser[sphinx]"
pip install myst-parser[sphinx]
```

Or for package development:
Expand All @@ -21,9 +24,6 @@ git checkout master
pip install -e .[sphinx,code_style,testing,rtd]
```

Note, this parser currently requires the [ExecutableBookProject/mistletoe](https://github.com/ExecutableBookProject/mistletoe)
fork of mistletoe (included in the above installation).

To use the MyST parser in Sphinx, simply add: `extensions = ["myst_parser"]` to your `conf.py`.

## Parsed Token Classes
Expand Down Expand Up @@ -104,3 +104,17 @@ Merging pull requests: There are three ways of 'merging' pull requests on GitHub
Examples: PRs that contain multiple commits with individually significant changes; PRs that have commits from different authors (squashing commits would remove attribution)
- Merge with merge commit: put all commits as they are on the base branch, with a merge commit on top
Choose for collaborative PRs with many commits. Here, the merge commit provides actual benefits.


[travis-badge]: https://travis-ci.org/ExecutableBookProject/MyST-Parser.svg?branch=master
[travis-link]: https://travis-ci.org/ExecutableBookProject/MyST-Parser
[coveralls-badge]: https://coveralls.io/repos/github/ExecutableBookProject/MyST-Parser/badge.svg?branch=master
[coveralls-link]: https://coveralls.io/github/ExecutableBookProject/MyST-Parser?branch=master
[rtd-badge]: https://readthedocs.org/projects/myst-parser/badge/?version=latest
[rtd-link]: https://myst-parser.readthedocs.io/en/latest/?badge=latest
[black-badge]: https://img.shields.io/badge/code%20style-black-000000.svg
[pypi-badge]: https://img.shields.io/pypi/v/myst-parser.svg
[pypi-link]: https://pypi.org/project/myst-parser
[conda-badge]: https://anaconda.org/conda-forge/myst-parser/badges/version.svg
[conda-link]: https://anaconda.org/conda-forge/myst-parser
[black-link]: https://github.com/ambv/black
1 change: 1 addition & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
git+https://github.com/pandas-dev/pandas-sphinx-theme.git@master
5 changes: 1 addition & 4 deletions docs/using/install.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Installing the MyST parser provides access to two tools:
To install the MyST parser, run the following:

```bash
pip install -e "git+https://github.com/ExecutableBookProject/MyST-Parser.git#egg=myst-parser[sphinx]"
pip install myst-parser[sphinx]
```

Or for package development:
Expand All @@ -19,6 +19,3 @@ cd MyST-Parser
git checkout master
pip install -e .[sphinx,code_style,testing,rtd]
```

This should install the myst fork of mistletoe, along with the Sphinx parser
that is included in the "extensions" configuration of this site.
2 changes: 1 addition & 1 deletion myst_parser/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from .utils import traverse # noqa: F401

__version__ = "0.3.0"
__version__ = "0.3.1"


def text_to_tokens(text: str):
Expand Down
16 changes: 2 additions & 14 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,7 @@
],
keywords="markdown lexer parser development docutils sphinx",
python_requires=">=3.5",
install_requires=[
(
"mistletoe @ "
"https://github.com/ExecutableBookProject/mistletoe/archive/myst.zip"
)
],
install_requires=["mistletoe-ebp==0.8.2"],
extras_require={
"sphinx": ["pyyaml", "docutils>=0.15", "sphinx>=2,<3"],
"code_style": ["flake8<3.8.0,>=3.7.0", "black", "pre-commit==1.17.0"],
Expand All @@ -51,14 +46,7 @@
"pytest-regressions",
"beautifulsoup4",
],
"rtd": [
"sphinxcontrib-bibtex",
"ipython",
(
"pandas_sphinx_theme @ "
"https://github.com/pandas-dev/pandas-sphinx-theme/archive/master.zip"
),
],
"rtd": ["sphinxcontrib-bibtex", "ipython"],
},
zip_safe=True,
)

0 comments on commit 6135ba8

Please sign in to comment.