Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update with black formatting and ruff linting #158

Merged
merged 10 commits into from
Nov 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 0 additions & 21 deletions .github/workflows/flake8.yml

This file was deleted.

11 changes: 11 additions & 0 deletions .github/workflows/python-linting.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: Check Python formatting using Black and Ruff

on: [push]

jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: psf/black@stable
- uses: chartboost/ruff-action@v1
12 changes: 12 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
repos:
- repo: https://github.com/psf/black
rev: 23.9.1
hooks:
- id: black
language_version: "python3.10"

- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: v0.0.292
hooks:
- id: ruff
language_version: "python3.10"
5 changes: 3 additions & 2 deletions agasc/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@


def test(*args, **kwargs):
'''
"""
Run py.test unit tests.
'''
"""
import testr

return testr.test(*args, **kwargs)
Loading