summaryrefslogtreecommitdiffstats
path: root/src/configs/elm.rs
diff options
context:
space:
mode:
authorThomas O'Donnell <andytom@users.noreply.github.com>2021-02-20 18:33:00 +0100
committerGitHub <noreply@github.com>2021-02-20 18:33:00 +0100
commit71b6fc17777bd587199a6c1b2c7e30e1a87535f7 (patch)
treed105d1a287228fbc957b9724c47384fdc2227474 /src/configs/elm.rs
parent9313e90773c8536e520bb34750345d7e4d4a6946 (diff)
feat(elm): Configure when the module is shown (#2341)
This makes it possible to configure when the elm module is shown based on the contents of a directory. This should make it possible to be a lot more granular when configuring the module.
Diffstat (limited to 'src/configs/elm.rs')
-rw-r--r--src/configs/elm.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/configs/elm.rs b/src/configs/elm.rs
index 17dc35686..801622cf4 100644
--- a/src/configs/elm.rs
+++ b/src/configs/elm.rs
@@ -8,6 +8,9 @@ pub struct ElmConfig<'a> {
pub symbol: &'a str,
pub style: &'a str,
pub disabled: bool,
+ pub detect_extensions: Vec<&'a str>,
+ pub detect_files: Vec<&'a str>,
+ pub detect_folders: Vec<&'a str>,
}
impl<'a> RootModuleConfig<'a> for ElmConfig<'a> {
@@ -17,6 +20,9 @@ impl<'a> RootModuleConfig<'a> for ElmConfig<'a> {
symbol: "🌳 ",
style: "cyan bold",
disabled: false,
+ detect_extensions: vec!["elm"],
+ detect_files: vec!["elm.json", "elm-package.json", ".elm-version"],
+ detect_folders: vec!["elm-stuff"],
}
}
}