aboutsummaryrefslogtreecommitdiff
path: root/languages.toml
diff options
context:
space:
mode:
authormidnightexigent2022-10-20 14:13:56 +0000
committerGitHub2022-10-20 14:13:56 +0000
commitd801a6693c3d475b3942f705d3ef48d7966bdf65 (patch)
treebac1900ae07756d79c66bfa6a2c8708f8c3ff2ff /languages.toml
parent78c0cdc519a2c76842441103b1ed716bb7c0a4e1 (diff)
Allow using path suffixes to associate language file-types (#2455)
* feat(syntax): add strategy to associate file to language through pattern File path will match if it ends with any of the file types provided in the config. Also used this feature to add support for the .git/config and .ssh/config files * Add /etc/ssh/ssh_config to languages.toml * cargo xtask docgen * Update languages.md * Update languages.md * Update book/src/languages.md Co-authored-by: Ivan Tham <pickfire@riseup.net> * Update book/src/languages.md Co-authored-by: Ivan Tham <pickfire@riseup.net> Co-authored-by: Ivan Tham <pickfire@riseup.net>
Diffstat (limited to 'languages.toml')
-rw-r--r--languages.toml2
1 files changed, 1 insertions, 1 deletions
diff --git a/languages.toml b/languages.toml
index 39b81731..ce3ba20a 100644
--- a/languages.toml
+++ b/languages.toml
@@ -1054,7 +1054,7 @@ name = "git-config"
scope = "source.gitconfig"
roots = []
# TODO: allow specifying file-types as a regex so we can read directory names (e.g. `.git/config`)
-file-types = [".gitmodules", ".gitconfig"]
+file-types = [".gitmodules", ".gitconfig", ".git/config", ".config/git/config"]
injection-regex = "git-config"
comment-token = "#"
indent = { tab-width = 4, unit = "\t" }