summaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorWaylan Limberg <waylan.limberg@icloud.com>2020-05-21 13:54:38 -0400
committerGitHub <noreply@github.com>2020-05-21 13:54:38 -0400
commitb7d64294c45104436d305b6c70a6c879928e73cd (patch)
treed8737e3c25ccdbdb39673bad832bf4449d2f9905 /.github
parent92ac78ba3261b1b3d61351ec8a999f5e5aa96ee4 (diff)
downloadpython-markdown-b7d64294c45104436d305b6c70a6c879928e73cd.tar.gz
Add deploy workflow (#971)
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/deploy.yml53
1 files changed, 53 insertions, 0 deletions
diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml
new file mode 100644
index 0000000..fca5318
--- /dev/null
+++ b/.github/workflows/deploy.yml
@@ -0,0 +1,53 @@
+name: deploy
+
+on:
+ push:
+ tags:
+ - '*'
+
+jobs:
+
+ pypi:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v2
+ - name: Setup Python
+ uses: actions/setup-python@v1
+ with:
+ python-version: 3.7
+ - name: Install dependencies
+ run: |
+ python -m pip install --upgrade pip setuptools wheel
+ - name: Build
+ run: |
+ python setup.py bdist_wheel sdist --formats gztar
+ - name: Publish
+ if: success()
+ uses: pypa/gh-action-pypi-publish@v1.1.0
+ with:
+ user: __token__
+ password: ${{ secrets.PYPI_PASSWORD }}
+
+ ghpages:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v2
+ - name: Setup Python
+ uses: actions/setup-python@v1
+ with:
+ python-version: 3.7
+ - name: Install dependencies
+ run: |
+ python -m pip install --upgrade pip setuptools
+ python -m pip install -r doc-requirements.txt
+ - name: Build
+ run: |
+ python -m mkdocs build --clean --verbose
+ - name: Publish
+ if: success()
+ uses: peaceiris/actions-gh-pages@v3
+ with:
+ deploy_key: ${{ secrets.PAGES_DEPLOY_KEY }}
+ external_repository: Python-Markdown/Python-Markdown.github.io
+ publish_branch: master
+ publish_dir: ./site