Skip to content

Commit

Permalink
fix SVG images (Lightning-AI#1409)
Browse files Browse the repository at this point in the history
  • Loading branch information
Borda authored Apr 7, 2020
1 parent 62822b6 commit f7622eb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ def load_long_describtion():
# https://github.com/PyTorchLightning/pytorch-lightning/raw/master/docs/source/_images/lightning_module/pt_to_pl.png
url = os.path.join(pytorch_lightning.__homepage__, 'raw', pytorch_lightning.__version__, 'docs')
text = open('README.md', encoding='utf-8').read()
# replace relative repository path to absolute link to the release
text = text.replace('](docs', f']({url}')
# SVG images are not readable on PyPI, so replace them with PNG
text = text.replace('.svg', '.svg')
return text


Expand Down

0 comments on commit f7622eb

Please sign in to comment.