diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a8a2a11..653493c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,7 +29,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ["3.10", "3.11", "3.12"] + python-version: ["3.10", "3.11", "3.12", "3.13", "3.14", "3.15-dev"] steps: - uses: actions/checkout@v4 diff --git a/README.md b/README.md index 597d0ca..1411051 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,10 @@

Sable logo +
+ Code style: Sable + PyPI version + Python 3.10 through 3.15-dev + License: MIT

An uncompromising Fortran formatter, inspired by [Black](https://github.com/psf/black). @@ -120,6 +125,28 @@ File-wide: ## Configuration +Formatter options are CLI flags: + +```bash +sable format --line-length 88 src/ +``` + +| Option | Default | Values | Applies to | +| --- | ---: | --- | --- | +| `--line-length` | `100` | integer | `format`, `check` | +| `--indent-width` | `3` | integer | `format`, `check` | +| `--keyword-case` | `lower` | `lower`, `upper` | `format`, `check` | +| `--end-keyword-form` | `spaced` | `spaced`, `compact` | `format`, `check` | +| `--no-normalize-operators` | off | flag | `format`, `check` | +| `rule_set` / `--rule-set` | `all` | `style`, `lint`, `all` | `check` | +| `select` / `--select` | `[]` | rule codes | `check` | +| `ignore` / `--ignore` | `[]` | rule codes | `check` | +| `output_format` / `--output-format` | `text` | `text`, `json`, `sarif`, `gitlab-codequality` | `check` | +| `baseline` / `--baseline` | unset | path | `check` | +| `fix` / `--fix` | `false` | boolean | `check` | +| `unsafe_fixes` / `--unsafe-fixes` | `false` | boolean | `check` | +| `generate_baseline` / `--generate-baseline` | `false` | boolean | `check` | + Example `pyproject.toml`: ```toml @@ -134,7 +161,13 @@ unsafe_fixes = false generate_baseline = false ``` -CLI flags override `pyproject.toml` defaults. +For `check`, CLI flags override `pyproject.toml` defaults. + +## Badge + +```markdown +[![Code style: Sable](https://raw.githubusercontent.com/eirik-kjonstad/sable/main/assets/sable-badge.svg)](https://github.com/eirik-kjonstad/sable) +``` ## License diff --git a/assets/sable-badge.svg b/assets/sable-badge.svg new file mode 100644 index 0000000..22acc3f --- /dev/null +++ b/assets/sable-badge.svg @@ -0,0 +1,24 @@ + + Code style: Sable + A badge indicating that code is formatted with Sable. + + + + + + + + + + + + + + + + code style + code style + sable + sable + + diff --git a/pyproject.toml b/pyproject.toml index 134e7ab..54e08c8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "hatchling.build" [project] name = "sable-fortran" -version = "0.3.8" +version = "0.3.9" description = "An uncompromising Fortran formatter, inspired by Black" readme = "README.md" requires-python = ">=3.10" @@ -19,6 +19,9 @@ classifiers = [ "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", + "Programming Language :: Python :: 3.13", + "Programming Language :: Python :: 3.14", + "Programming Language :: Python :: 3.15", "Topic :: Software Development :: Quality Assurance", ] dependencies = [ diff --git a/src/sable/__init__.py b/src/sable/__init__.py index 74d18ad..1168c6c 100644 --- a/src/sable/__init__.py +++ b/src/sable/__init__.py @@ -1,3 +1,3 @@ """Sable: an uncompromising Fortran formatter.""" -__version__ = "0.3.8" +__version__ = "0.3.9"