Skip to content

build(deps): Bump bufbuild/buf-setup-action from 1.47.2 to 1.48.0 (#1… #1695

build(deps): Bump bufbuild/buf-setup-action from 1.47.2 to 1.48.0 (#1…

build(deps): Bump bufbuild/buf-setup-action from 1.47.2 to 1.48.0 (#1… #1695

name: configs-json-lint
on: [push, pull_request]
jobs:
lint:
name: configs JSON lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check configs JSON format
run: |
files=("config_example.json" "testdata/configtest.json")
for file in "${files[@]}"; do
processed_file="${file%.*}_processed.${file##*.}"
jq '.exchanges |= sort_by(.name)' --indent 1 $file > $processed_file
if ! diff $file $processed_file; then
echo "jq differences found in $file! Please run 'make lint_configs'"
exit 1
else
rm $processed_file
echo "No differences found in $file 🌞"
fi
done