Skip to content
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
4 changes: 2 additions & 2 deletions .github/workflows/cron.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ jobs:
python-version: '3.x'

- name: install tox
run: python -m pip install 'tox'
run: python -m pip install 'tox' 'rust-just'

- name: vendor-schemas
run: make vendor-schemas
run: just vendor-schemas

# this action seems to have significant usage, so it should be stable
# can always re-implement with `git status --porcelain`, etc. if necessary
Expand Down
50 changes: 25 additions & 25 deletions .pre-commit-hooks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-azure-pipelines
name: Validate Azure Pipelines
description: 'Validate Azure Pipelines config against the schema provided by Microsoft'
Expand All @@ -31,7 +31,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-bamboo-spec
name: Validate Bamboo Specs
description: 'Validate Bamboo Specs against the schema provided by SchemaStore'
Expand All @@ -42,7 +42,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-bitbucket-pipelines
name: Validate Bitbucket Pipelines
description: 'Validate Bitbucket Pipelines against the schema provided by SchemaStore'
Expand All @@ -53,7 +53,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-buildkite
name: Validate Buildkite Pipelines
description: 'Validate Buildkite Pipelines against the schema provided by Buildkite'
Expand All @@ -70,7 +70,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-circle-ci
name: Validate CircleCI config
description: 'Validate CircleCI config against the schema provided by SchemaStore'
Expand All @@ -80,7 +80,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-citation-file-format
name: Validate Citation File Format
description: 'Validate Citation File Format'
Expand All @@ -90,7 +90,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-cloudbuild
name: Validate Google Cloud Build config
description: 'Validate Google Cloud Build config against the schema provided by SchemaStore'
Expand All @@ -101,7 +101,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-codecov
name: Validate Codecov config
description: 'Validate Codecov config against the schema provided by SchemaStore'
Expand All @@ -115,7 +115,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-compose-spec
name: Validate Docker Compose files
description: 'Validate Docker Compose files against the schema provided by SchemaStore'
Expand All @@ -130,7 +130,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-dependabot
name: Validate Dependabot Config (v2)
description: 'Validate Dependabot Config (v2) against the schema provided by SchemaStore'
Expand All @@ -141,7 +141,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-drone-ci
name: Validate Drone-CI Config
description: 'Validate Drone-CI Config against the schema provided by SchemaStore'
Expand All @@ -152,7 +152,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-github-actions
name: Validate GitHub Actions
description: 'Validate GitHub Actions against the schema provided by SchemaStore'
Expand All @@ -167,7 +167,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-github-discussion
name: Validate GitHub discussion
description: 'Validate GitHub discussion against the schema provided by SchemaStore'
Expand All @@ -181,7 +181,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-github-issue-config
name: Validate GitHub issue config
description: 'Validate GitHub issue config against the schema provided by SchemaStore'
Expand All @@ -195,7 +195,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-github-issue-forms
name: Validate GitHub issue forms
description: 'Validate GitHub issue forms against the schema provided by SchemaStore'
Expand All @@ -209,7 +209,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-github-workflows
name: Validate GitHub Workflows
description: 'Validate GitHub Workflows against the schema provided by SchemaStore'
Expand All @@ -220,7 +220,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-gitlab-ci
name: Validate GitLab CI config
description: 'Validate GitLab CI config against the schema provided by SchemaStore'
Expand All @@ -231,7 +231,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-meltano
name: Validate Meltano Config
description: 'Validate Meltano config against the schema provided by Meltano'
Expand All @@ -247,7 +247,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-mergify
name: Validate Mergify config
description: 'Validate Mergify config against the schema provided by SchemaStore'
Expand All @@ -263,7 +263,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-readthedocs
name: Validate ReadTheDocs Config
description: 'Validate ReadTheDocs config against the schema provided by ReadTheDocs'
Expand All @@ -274,7 +274,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-renovate
name: Validate Renovate Config
description: 'Validate Renovate config against the schema provided by Renovate (does not support renovate config in package.json)'
Expand All @@ -290,7 +290,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-snapcraft
name: Validate snapcraft files
description: 'Validate snapcraft files against the schema provided by Canonical'
Expand All @@ -301,7 +301,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-taskfile
name: Validate Taskfile Config
description: 'Validate Taskfile config against the schema provided by Task'
Expand All @@ -318,7 +318,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-travis
name: Validate Travis Config
description: 'Validate Travis Config against the schema provided by SchemaStore'
Expand All @@ -329,7 +329,7 @@

# this hook is autogenerated from a script
# to modify this hook, update `src/check_jsonschema/catalog.py`
# and run `make generate-hooks` or `tox run -e generate-hooks-config`
# and run `just generate-hooks` or `tox run -e generate-hooks-config`
- id: check-woodpecker-ci
name: Validate Woodpecker Config
description: 'Validate Woodpecker Config against the schema provided by SchemaStore'
Expand Down
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,12 @@ These files are automatically picked up by the testsuite and checked.
Hooks are defined in `src/check_jsonschema/catalog.py`, and rendered to
`.pre-commit-hooks.yaml` with the generator script. It can be run with

make generate-hooks
just generate-hooks

Schemas are pulled down based on this same config. If you want to update the
vendored schema copies, run

make vendor-schemas
just vendor-schemas

## Documentation

Expand Down
26 changes: 0 additions & 26 deletions Makefile

This file was deleted.

2 changes: 1 addition & 1 deletion RELEASING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@

- Bump the version with `./scripts/bump-version.py NEW_VERSION`
- Add, commit with `git commit -m 'Bump version for release'`, and push
- Create a release tag, which will auto-publish to testpypi (`make release`)
- Create a release tag, which will auto-publish to testpypi (`just tag-release`)
- Create a GitHub release, which will auto-publish to pypi (web UI)
26 changes: 26 additions & 0 deletions justfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
version := `uvx mddj read version`
push_remote := `git rev-parse --abbrev-ref @{push} | cut -d '/' -f1`

lint:
pre-commit run -a
tox run -e mypy

test:
tox p

vendor-schemas:
tox run -e vendor-schemas

generate-hooks:
tox run -e generate-hooks-config

tag-release:
git tag -s "{{version}}" -m "v{{version}}"
git push {{push_remote}} refs/tags/{{version}}

collated-test-report: test
python ./scripts/aggregate-pytest-reports.py .tox/*/pytest.xml

clean:
rm -rf dist build *.egg-info .tox .coverage.*
find . -type d -name '__pycache__' -exec rm -r {} +
2 changes: 1 addition & 1 deletion scripts/generate-hooks-config.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def update_hook_config(new_config: str) -> None:
def generate_hook_lines(config) -> t.Iterator[str]:
yield "# this hook is autogenerated from a script"
yield "# to modify this hook, update `src/check_jsonschema/catalog.py`"
yield "# and run `make generate-hooks` or `tox run -e generate-hooks-config`"
yield "# and run `just generate-hooks` or `tox run -e generate-hooks-config`"
yield f"- id: {config['id']}"
yield f" name: {config['name']}"
yield f" description: '{config['description']}'"
Expand Down
Loading