elasticsearch_exporter/scripts/lint-jsonnet.sh
Joe Adams 3774123827
Refactor mixin dashboards (#885)
This is a complete refactor of the dashboard system. It brings the dashboard creation, metrics, alerting, etc into alignment with other projects that use jsonnet/grafonnet/mixins. This should allow users to customize what we have created and deploy into their environments. The dashboard was the focus of this iteration, reaching parity with the previous dashboard.

- Add in jsonnet and grafonnet
- Add scripts to compile and lint mixin
- Add CI for the mixin

---------

Signed-off-by: Joe Adams <github@joeadams.io>
2024-12-14 11:52:05 -05:00

14 lines
332 B
Bash
Executable File

#!/bin/bash
# Run lint on all jsonnet files in the repository
RESULT=0;
for f in $(find . -name 'vendor' -prune -o -name '*.libsonnet' -print -o -name '*.jsonnet' -print); do
# jsonnet fmt -i "$$f"
echo "Linting ${f}"
jsonnetfmt -- "${f}" | diff -u "${f}" -
RESULT=$((RESULT+$?))
done
echo "Linting complete"
exit $RESULT