We welcome contributions to the project!
All contributions to this project are welcome. To propose changes, we encourage contributors to:
- Fork this project on GitHub
- Create a new branch
- Propose changes by opening a new pull request. If you're looking for somewhere to start, check out the issues labeled "Good first issue" or Community.
We encourage contributors to format pull request titles following the Conventional Commit Specification.
- gbfs-validator
This is the heart of the validator. This folder contains a NodeJs package to validate GBFS Feeds.
- gbfs-validator/schema
Contains JSON schemas
- website
Contains the frontend, currently hosted by Netlify on https://gbfs-validator.mobilitydata.org/ It’s a tiny Vue SPA.
- functions
The API for the website uses a “lambda function”. This folder contains the lambda function. The function will depend on the gbfs-validator package. The function is only compatible with Netlify Function (https://www.netlify.com/products/functions/) for now.
- check-systems
Check-systems is a CLI tool to validate the whole “systems.csv” from https://github.com/MobilityData/gbfs locally
"Sticking to a single consistent and documented coding style for this project is important to ensure that code reviewers dedicate their attention to the functionality of the validation, as opposed to disagreements about the coding style (and avoid bike-shedding https://en.wikipedia.org/wiki/Law_of_triviality )." This project uses the Eslint + Prettier to ensure lint (See .eslintrc.js and .prettierrc)
For adding a new version:
- Create a new folder under “gbfs-validator/schema” with the version as name (Eg: “vX.Y”).
- Add an “index.js” file. This file will define the possible JSON-schema to call for validation and the mandatory ones. See master/gbfs-validator/schema/v2.2/index.js for an exemple.
- Fill the folder with all JSON-schemas for this version.
- Add an item on this array: master/website/src/components/Validator.vue#L98 with the new version to be made available on the website.