Skip to content

Commit

Permalink
Add toml formatter config + run make fmt.
Browse files Browse the repository at this point in the history
  • Loading branch information
brocaar committed Sep 9, 2024
1 parent 1e6286d commit 185048b
Show file tree
Hide file tree
Showing 9 changed files with 79 additions and 7 deletions.
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
.PHONY: test
.PHONY: test fmt devshell

test:
docker compose run --rm lorawan-device-profiles --run 'cd test-runner && cargo run'

fmt:
docker compose run --rm lorawan-device-profiles --run 'taplo fmt'

devshell:
docker-compose run --rm lorawan-device-profiles
1 change: 1 addition & 0 deletions shell.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@
pkgs.mkShell {
buildInputs = [
pkgs.rustup
pkgs.taplo
];
}
5 changes: 5 additions & 0 deletions taplo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
include = ["vendors/**/*.toml"]

[formatting]
indent_tables = true
indent_entries = true
13 changes: 12 additions & 1 deletion vendors/rakwireless/devices/rak10702.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,18 @@
# List of supported profiles.
#
# This list refers to one or multiple profiles in the profiles/ directory.
profiles = ["EU868_1_0_2.toml", "RU864_1_0_2.toml", "IN865_1_0_2.toml", "US915_1_0_2.toml", "AU915_1_0_2.toml", "KR920_1_0_2.toml", "AS923_1_1_0_2.toml", "AS923_2_1_0_2.toml", "AS923_3_1_0_2.toml", "AS923_4_1_0_2.toml"]
profiles = [
"EU868_1_0_2.toml",
"RU864_1_0_2.toml",
"IN865_1_0_2.toml",
"US915_1_0_2.toml",
"AU915_1_0_2.toml",
"KR920_1_0_2.toml",
"AS923_1_1_0_2.toml",
"AS923_2_1_0_2.toml",
"AS923_3_1_0_2.toml",
"AS923_4_1_0_2.toml",
]

# Payload codec.
#
Expand Down
13 changes: 12 additions & 1 deletion vendors/rakwireless/devices/wisblock-api-v2.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,18 @@
# List of supported profiles.
#
# This list refers to one or multiple profiles in the profiles/ directory.
profiles = ["EU868_1_0_2.toml", "RU864_1_0_2.toml", "IN865_1_0_2.toml", "US915_1_0_2.toml", "AU915_1_0_2.toml", "KR920_1_0_2.toml", "AS923_1_1_0_2.toml", "AS923_2_1_0_2.toml", "AS923_3_1_0_2.toml", "AS923_4_1_0_2.toml"]
profiles = [
"EU868_1_0_2.toml",
"RU864_1_0_2.toml",
"IN865_1_0_2.toml",
"US915_1_0_2.toml",
"AU915_1_0_2.toml",
"KR920_1_0_2.toml",
"AS923_1_1_0_2.toml",
"AS923_2_1_0_2.toml",
"AS923_3_1_0_2.toml",
"AS923_4_1_0_2.toml",
]

# Payload codec.
#
Expand Down
13 changes: 12 additions & 1 deletion vendors/rakwireless/devices/wisblock-kit-1.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,18 @@
# List of supported profiles.
#
# This list refers to one or multiple profiles in the profiles/ directory.
profiles = ["EU868_1_0_2.toml", "RU864_1_0_2.toml", "IN865_1_0_2.toml", "US915_1_0_2.toml", "AU915_1_0_2.toml", "KR920_1_0_2.toml", "AS923_1_1_0_2.toml", "AS923_2_1_0_2.toml", "AS923_3_1_0_2.toml", "AS923_4_1_0_2.toml"]
profiles = [
"EU868_1_0_2.toml",
"RU864_1_0_2.toml",
"IN865_1_0_2.toml",
"US915_1_0_2.toml",
"AU915_1_0_2.toml",
"KR920_1_0_2.toml",
"AS923_1_1_0_2.toml",
"AS923_2_1_0_2.toml",
"AS923_3_1_0_2.toml",
"AS923_4_1_0_2.toml",
]

# Payload codec.
#
Expand Down
13 changes: 12 additions & 1 deletion vendors/rakwireless/devices/wisblock-kit-2.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,18 @@
# List of supported profiles.
#
# This list refers to one or multiple profiles in the profiles/ directory.
profiles = ["EU868_1_0_2.toml", "RU864_1_0_2.toml", "IN865_1_0_2.toml", "US915_1_0_2.toml", "AU915_1_0_2.toml", "KR920_1_0_2.toml", "AS923_1_1_0_2.toml", "AS923_2_1_0_2.toml", "AS923_3_1_0_2.toml", "AS923_4_1_0_2.toml"]
profiles = [
"EU868_1_0_2.toml",
"RU864_1_0_2.toml",
"IN865_1_0_2.toml",
"US915_1_0_2.toml",
"AU915_1_0_2.toml",
"KR920_1_0_2.toml",
"AS923_1_1_0_2.toml",
"AS923_2_1_0_2.toml",
"AS923_3_1_0_2.toml",
"AS923_4_1_0_2.toml",
]

# Payload codec.
#
Expand Down
13 changes: 12 additions & 1 deletion vendors/rakwireless/devices/wisblock-kit-4.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,18 @@
# List of supported profiles.
#
# This list refers to one or multiple profiles in the profiles/ directory.
profiles = ["EU868_1_0_2.toml", "RU864_1_0_2.toml", "IN865_1_0_2.toml", "US915_1_0_2.toml", "AU915_1_0_2.toml", "KR920_1_0_2.toml", "AS923_1_1_0_2.toml", "AS923_2_1_0_2.toml", "AS923_3_1_0_2.toml", "AS923_4_1_0_2.toml"]
profiles = [
"EU868_1_0_2.toml",
"RU864_1_0_2.toml",
"IN865_1_0_2.toml",
"US915_1_0_2.toml",
"AU915_1_0_2.toml",
"KR920_1_0_2.toml",
"AS923_1_1_0_2.toml",
"AS923_2_1_0_2.toml",
"AS923_3_1_0_2.toml",
"AS923_4_1_0_2.toml",
]

# Payload codec.
#
Expand Down
8 changes: 7 additions & 1 deletion vendors/rakwireless/vendor.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,13 @@
# List of devices.
#
# This list refers to one or multiple devices in the devices/ directory.
devices = ["rak10702.toml", "wisblock-api-v2.toml", "wisblock-kit-1.toml", "wisblock-kit-2.toml", "wisblock-kit-4.toml"]
devices = [
"rak10702.toml",
"wisblock-api-v2.toml",
"wisblock-kit-1.toml",
"wisblock-kit-2.toml",
"wisblock-kit-4.toml",
]

# Vendor metadata (optional).
[vendor.metadata]
Expand Down

0 comments on commit 185048b

Please sign in to comment.