-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* create publish/release workflow * enable lcviz.test() * populate initial change log file * update to use trusted publishing * pin jdaviz 3.8.* for first release * fix toxenv for 3.9 test --------- Co-authored-by: P. L. Lim <[email protected]>
- Loading branch information
Showing
5 changed files
with
64 additions
and
5 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
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,52 @@ | ||
name: Release | ||
|
||
on: | ||
# NOTE: PR trigger is to ensure changes do not break packaging. | ||
pull_request: | ||
release: | ||
types: [released] | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
build-n-publish: | ||
name: Build and publish Python 🐍 distributions 📦 to PyPI | ||
runs-on: ubuntu-latest | ||
permissions: | ||
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing | ||
if: github.repository == 'spacetelescope/lcviz' | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.9 | ||
|
||
- name: Install python-build and twine | ||
run: python -m pip install build "twine>=3.3" | ||
|
||
- name: Build package | ||
run: python -m build --sdist --wheel . | ||
|
||
- name: List result | ||
run: ls -l dist | ||
|
||
- name: Check dist | ||
run: python -m twine check --strict dist/* | ||
|
||
- name: Test package | ||
run: | | ||
cd .. | ||
python -m venv testenv | ||
testenv/bin/pip install pytest pytest-astropy pytest-tornasync lcviz/dist/*.whl | ||
testenv/bin/python -c "import lcviz; lcviz.test(remote_data=True)" | ||
# NOTE: Do not run this part for PR testing. | ||
- name: Publish distribution 📦 to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
if: github.event_name != 'pull_request' |
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 |
---|---|---|
@@ -1,4 +1,5 @@ | ||
Changes included in this version | ||
-------------------------------- | ||
0.1.0 - unreleased | ||
------------------ | ||
|
||
Edit this template to detail updates to the codebase | ||
* Initial release of lcviz with support to import time-series light curves via lightkurve and | ||
process them through binning, flattening, frequency analysis, and ephemeris plugins. |
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