commit 136fa62e04dceb955e04efc4dbc52f7c0a2bd9a3 Author: cn Date: Sat Nov 11 16:15:44 2017 +0100 Fiat lux diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..749a153 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,7 @@ +# Changelog + +## 1.0.0 (November 11, 2017) + +NEW FEATURES: + +- Initial release of the [Sublime Text package](https://github.com/sixty4k/st2-zonefile) as package for Atom diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..c087e6d --- /dev/null +++ b/LICENSE @@ -0,0 +1,20 @@ +Copyright (c) 2016 Christian Nicolai + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..6164621 --- /dev/null +++ b/README.md @@ -0,0 +1,7 @@ +# Bind Zone File language support in Atom + +Adds basic syntax highlighting based on the [Sublime Text package](https://github.com/sixty4k/st2-zonefile) to zone files in Atom. + +## License + +language-zonefile is licensed under the MIT License. See LICENSE for more information. diff --git a/grammars/zonefile.cson b/grammars/zonefile.cson new file mode 100644 index 0000000..b2789e9 --- /dev/null +++ b/grammars/zonefile.cson @@ -0,0 +1,58 @@ +scopeName: 'source.zonefile' +name: 'Bind Zone File' +fileTypes: [ + 'zone' + 'db' +] +patterns: [ + { + match: ';.*' + name: 'comment.line.semicolon.zonefile' + } + { + match: '@' + name: 'keyword.directive.zonefile' + } + { + match: '\\$(ORIGIN|origin|TTL|ttl|INCLUDE|include)\\s*([^;]*)(;.*)?' + name: 'keyword.directive.zonefile' + captures: + '2': + name: 'variable.other.directive.zonefile' + '3': + name: 'comment.line.semicolon.zonefile' + } + { + match: '\\d+(H|h|D|d|W|w|M|m|Y|y)' + name: 'variable.other.timeunit.zonefile' + } + { + begin: '([A-Za-z0-9_.-]*)\\s+(?:([0-9A-Za-z]*)\\s+)?([I|i][N|n]\\s+[A-Za-z0-9]+)\\s+(.*)\\(' + beginCaptures: + '2': + name: 'variable.other.timeunit.zonefile' + '3': + name: 'keyword.resourcetype.zonefile' + '4': + name: 'string.quoted.single.resource.address.zonefile' + end: '\\)' + name: 'string.quoted.single.address.zonefile' + patterns: [ + { + match: ';.*' + name: 'comment.line.semicolon.zonefile' + } + ] + } + { + match: '([A-Za-z0-9_.-]*)\\s+(?:([0-9A-Za-z]*)\\s+)?([I|i][N|n]\\s+[A-Za-z0-9]+)\\s+(.*)' + name: 'string.quoted.single.address.zonefile' + captures: + '2': + name: 'variable.other.timeunit.zonefile' + '3': + name: 'keyword.resourcetype.zonefile' + '4': + name: 'string.quoted.single.resource.address.zonefile' + } +] diff --git a/package.json b/package.json new file mode 100644 index 0000000..544c068 --- /dev/null +++ b/package.json @@ -0,0 +1,17 @@ +{ + "name": "language-zonefile", + "description": "Bind Zone File language support in Atom", + "version": "0.0.0", + "engines": { + "atom": "*" + }, + "homepage": "https://github.com/cmur2/language-zonefile", + "repository": { + "type": "git", + "url": "https://github.com/cmur2/language-zonefile.git" + }, + "license": "MIT", + "bugs": { + "url": "https://github.com/cmur2/language-zonefile/issues" + } +}