From cffc1be9f231915612910b7b786692995c9a0985 Mon Sep 17 00:00:00 2001 From: Leo Singer Date: Tue, 5 Nov 2024 14:46:04 -0500 Subject: [PATCH] Add instructions for configuring pre-commit hooks in schema repo --- app/routes/docs.notices.schema.mdx | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/app/routes/docs.notices.schema.mdx b/app/routes/docs.notices.schema.mdx index 5362dff8a..0f44dafa8 100644 --- a/app/routes/docs.notices.schema.mdx +++ b/app/routes/docs.notices.schema.mdx @@ -22,6 +22,18 @@ As you are developing your schema, don't hesitate to [contact us](/contact) with To get started, fork the [nasa-gcn/gcn-schema](https://github.com/nasa-gcn/gcn-schema) repository on GitHub and check it out on your computer. If you are new to GitHub, refer to our [GitHub primer](/docs/contributing/github). +After you have forked and cloned the repository, make sure that Node.js and NPM are installed on your computer. There are several options to install Node.js and NPM. Pick _one_ of the following: + +- Download and run [the Node.js installer for your operating system](https://nodejs.org/en/download/). +- Install and use the [Node Version Manager, nvm](https://github.com/nvm-sh/nvm). +- Install using a [package manager](https://nodejs.org/en/download/package-manager/). + +Finally, run the following command inside the repository working directory to install the pre-commit hooks for code formatting and syntax checking: + +``` +npm install +``` + ## File Naming Conventions Create a folder in the repository for your mission following the naming convention gcn/notices/mission. Add one or more files for schema definitions named gcn/notices/mission/schema_name.schema.json. The mission name should be lowercase and the schema name should be [snake_case](https://en.wikipedia.org/wiki/Snake_case). Each file corresponds to a [Kafka topic](/docs/notices/producers) named gcn.notices.mission.schema_name.