From 15b1676b7205999db3bd0057fd8504937452111c Mon Sep 17 00:00:00 2001 From: Anubhab Ghosh Date: Wed, 23 Oct 2019 23:54:46 +0530 Subject: [PATCH] Add syntax highlighting for /etc/group file --- assets/syntaxes/Group.sublime-syntax | 48 ++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 assets/syntaxes/Group.sublime-syntax diff --git a/assets/syntaxes/Group.sublime-syntax b/assets/syntaxes/Group.sublime-syntax new file mode 100644 index 00000000..febe3edb --- /dev/null +++ b/assets/syntaxes/Group.sublime-syntax @@ -0,0 +1,48 @@ +%YAML 1.2 +--- +# http://www.sublimetext.com/docs/3/syntax.html +name: group +file_extensions: + - group +scope: source.group + +contexts: + main: + - comment: name + match: ^[^:]+ + scope: keyword + + - comment: password + match: ":" + push: password + + password: + - comment: uid + match: ":" + set: gid + + - comment: shadowpassword + match: "[^:]+" + scope: invalid + + gid: + - comment: gid + match: ":" + set: users + + - comment: number + match: "[0-9]+" + scope: constant.numeric + + users: + - comment: newline + match: "\n" + pop: true + + - comment: directory + match: "[^:\n]+" + scope: variable.parameter + + - comment: separator + match: "," + scope: punctuation