Skip to content

Commit

Permalink
Complete modernization and upgrading
Browse files Browse the repository at this point in the history
  • Loading branch information
Myoldmopar committed Jul 30, 2024
1 parent ab47208 commit 1ad8b43
Show file tree
Hide file tree
Showing 31 changed files with 1,248 additions and 884 deletions.
6 changes: 6 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[run]
source = solar_angles

[report]
omit =
*/solar_angles/demos/*.py
2 changes: 2 additions & 0 deletions .flake8
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[flake8]
max-line-length = 120
21 changes: 21 additions & 0 deletions .github/workflows/flake8.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Flake8

on: [push]

jobs:
flake8:
runs-on: ubuntu-24.04

steps:
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # v2

- name: Set up Python
uses: actions/setup-python@d27e3f3d7c64b4bbf8e4abfb9b63b83e846e0435 # v4.5.0
with:
python-version: 3.12

- name: Install Pip Dependencies
run: pip install flake8

- name: Run Flake8
run: flake8 solar_angles
38 changes: 38 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: PyPIRelease

on:
push:
tags:
- '*'

defaults:
run:
shell: bash

jobs:
release:
runs-on: ubuntu-24.04

steps:
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # v2

- name: Set up Python
uses: actions/setup-python@d27e3f3d7c64b4bbf8e4abfb9b63b83e846e0435 # v4.5.0
with:
python-version: 3.12

- name: Install Dependencies for Building Wheels
run: pip install wheel

# - name: Install Dependent Packages
# run: pip install .
# # note that this is not necessary for building the package, it just ensures compatability

- name: Build the Wheel
run: rm -rf dist/ build/ && python3 setup.py bdist_wheel sdist

- name: Deploy on Test PyPi
uses: pypa/gh-action-pypi-publish@37f50c210e3d2f9450da2cd423303d6a14a6e29f # v1.5.1
with:
user: __token__
password: ${{ secrets.PYPIPW }}
27 changes: 27 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: DevelopmentTest

on: [push]

jobs:
test_compatability: # not actually running tests, just testing dependencies are compatible
strategy:
matrix:
os: [ windows-latest, macos-12, ubuntu-24.04 ]
py: [ "3.11", "3.12"" ]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # v2
- name: Set up Python
uses: actions/setup-python@d27e3f3d7c64b4bbf8e4abfb9b63b83e846e0435 # v4.5.0
with:
python-version: ${{ matrix.py }}
- name: Install Pip Dependencies from Requirements
shell: bash
run: pip install -r requirements.txt
- name: Run Tests
run: coverage run -m pytest && coverage report -m
- name: Coveralls
if: ${{ matrix.os == 'ubuntu-24.04' }}
run: coveralls --service=github
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2 changes: 2 additions & 0 deletions .gitignore
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
.idea/

# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
Expand Down
20 changes: 20 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Set the OS, Python version and other tools you might need
build:
os: ubuntu-22.04
tools:
python: "3.12"

# Build documentation in the "docs/" directory with Sphinx
sphinx:
configuration: docs/conf.py

# Optional but recommended, declare the Python requirements required
# See https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
# python:
# install:
# - requirements: docs/requirements.txt
3 changes: 0 additions & 3 deletions .travis.yml

This file was deleted.

Empty file modified LICENSE
100644 → 100755
Empty file.
Empty file modified README.md
100644 → 100755
Empty file.
52 changes: 0 additions & 52 deletions demos/CompareToEplus.py

This file was deleted.

177 changes: 0 additions & 177 deletions demos/SolarAngles.py

This file was deleted.

Empty file modified docs/Makefile
100644 → 100755
Empty file.
Loading

0 comments on commit 1ad8b43

Please sign in to comment.