From 267da9e4381c68437568096a59017f2b858d5659 Mon Sep 17 00:00:00 2001 From: Kyle Robbertze Date: Thu, 9 Jan 2025 07:53:49 +0000 Subject: [PATCH] chore: add pre-commit API check (#3120) ### Description This is a way of ensuring the schema is up to date with every change. This should be extended by fixing the PR api schema pipeline to squash down all PR commits into a single change and checking the API schema for that. Otherwise people will fix the schema after a failed pipeline and the pipeline will continue to fail --- .pre-commit-config.yaml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 37760d99d..f7a7abd26 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -110,3 +110,11 @@ repos: pass_filenames: false language: script files: ^legacy + + - id: api-schema-update + name: api-schema-update + description: Ensure API schema is up to date + entry: make -C api schema + pass_filenames: false + language: system + files: ^api