From 8a53f9ecedd3860cbad736f2ea0e5f31ef4e12bb Mon Sep 17 00:00:00 2001 From: DefectingCat Date: Thu, 13 Apr 2023 20:01:58 +0800 Subject: [PATCH] Add example config file --- .editorconfig | 3 +++ config.example.json | 8 ++++++++ src/config.rs | 1 + src/logger.rs | 0 src/main.rs | 5 ++++- 5 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 config.example.json create mode 100644 src/config.rs create mode 100644 src/logger.rs diff --git a/.editorconfig b/.editorconfig index d8c1f4b..3e4aec1 100644 --- a/.editorconfig +++ b/.editorconfig @@ -13,3 +13,6 @@ indent_size = 4 [*.{diff,md}] trim_trailing_whitespace = false + +[*.json] +indent_size = 2 \ No newline at end of file diff --git a/config.example.json b/config.example.json new file mode 100644 index 0000000..2c4b93f --- /dev/null +++ b/config.example.json @@ -0,0 +1,8 @@ +{ + "log_level": "info", + + "list": { + "exact": ["19240158324"], + "wildcard": ["1924015*", "192*8324", "*40158324"] + } +} \ No newline at end of file diff --git a/src/config.rs b/src/config.rs new file mode 100644 index 0000000..63e25a5 --- /dev/null +++ b/src/config.rs @@ -0,0 +1 @@ +pub struct Config {} \ No newline at end of file diff --git a/src/logger.rs b/src/logger.rs new file mode 100644 index 0000000..e69de29 diff --git a/src/main.rs b/src/main.rs index e7a11a9..ac2a9e1 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,3 +1,6 @@ +mod config; +mod logger; + fn main() { println!("Hello, world!"); -} +} \ No newline at end of file