diff options
author | Clement Tsang <34804052+ClementTsang@users.noreply.github.com> | 2021-01-01 18:09:28 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-01 18:09:28 -0500 |
commit | 90be9730a62e2a935ccf01cdd6e320c65624722a (patch) | |
tree | b22a66210a2af97f0ced92dc27d89a6ad2137f63 /src/app.rs | |
parent | d8d72d060d4bd4473bfe769673a2227bda948c97 (diff) |
feature: Add network interface filtering (#381)
Adds a new option in the config file to filter out network interfaces. Also add the option to filter by whole words.
Interface follows that of the existing ones:
```toml
[net_filter]
is_list_ignored = false
list = ["virbr0.*"]
regex = true
case_sensitive = false
whole_word = false
```
Diffstat (limited to 'src/app.rs')
-rw-r--r-- | src/app.rs | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -57,12 +57,14 @@ pub struct AppConfigFields { } /// For filtering out information +#[derive(Debug, Clone)] pub struct DataFilters { pub disk_filter: Option<Filter>, pub temp_filter: Option<Filter>, + pub net_filter: Option<Filter>, } -#[derive(Debug)] +#[derive(Debug, Clone)] pub struct Filter { pub is_list_ignored: bool, pub list: Vec<regex::Regex>, |