forked from sympy/sympy
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request sympy#21275 from oscarbenjamin/pr_release_script_ci
maint(release): run release script in CI
- Loading branch information
Showing
5 changed files
with
102 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
# ------------------------------------------------------------------ # | ||
# # | ||
# SymPy CI script for Github Actions # | ||
# # | ||
# Run on the release branch and builds the release artifacts. # | ||
# # | ||
# ------------------------------------------------------------------ # | ||
|
||
name: release | ||
on: | ||
push: | ||
branches: | ||
- 1.8 | ||
pull_request: | ||
branches: | ||
- 1.8 | ||
env: | ||
release_branch: 1.8 | ||
release_version: 1.8 | ||
|
||
jobs: | ||
|
||
# -------------------- Build artifacts --------------------------- # | ||
|
||
build: | ||
|
||
runs-on: ubuntu-20.04 | ||
steps: | ||
# Check out with full git history for authors check: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.8 | ||
|
||
- name: Build release files | ||
run: release/ci_release_script.sh ${{ env.release_version }} | ||
|
||
- name: Store release files | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: release_files | ||
path: release-${{ env.release_version }} | ||
|
||
# -------------------- Test installation ------------------------- # | ||
|
||
test-install: | ||
needs: [build] | ||
|
||
runs-on: ubuntu-20.04 | ||
strategy: | ||
matrix: | ||
python-version: ['3.6', '3.7', '3.8', '3.9', 'pypy-3.6'] | ||
|
||
name: Python ${{ matrix.python-version }} test install | ||
steps: | ||
- name: Setup python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
architecture: x64 | ||
|
||
- name: Retrieve release files | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: release_files | ||
|
||
- name: List files | ||
run: ls -R | ||
|
||
- name: Install wheel | ||
run: pip install sympy-${{ env.release_version }}-py3-none-any.whl | ||
|
||
- name: Run tests after install | ||
run: python -c 'import sympy; sympy.test()' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#!/usr/bin/env bash | ||
|
||
release/aptinstall.sh | ||
|
||
python3 -m venv release/venv_main | ||
source release/venv_main/bin/activate | ||
|
||
pip install -U pip wheel | ||
pip install -r release/requirements.txt | ||
pip install -e . | ||
|
||
python release/releasecheck.py $1 release-$1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters