1
0
mirror of https://github.com/cmur2/language-fluentd.git synced 2024-12-22 12:54:26 +01:00

docs: change syntax name, add example

This commit is contained in:
cn 2017-11-23 20:15:36 +01:00
parent b60e1034bc
commit 813fde30c0
5 changed files with 73 additions and 4 deletions

View File

@ -1,5 +1,11 @@
# Changelog # Changelog
## 1.1.0
IMPROVEMENTS:
- Add example Fluentd Configuration file using as many Fluentd features as possible even if they are not highlighted correctly
## 1.0.0 (November 22, 2017) ## 1.0.0 (November 22, 2017)
NEW FEATURES: NEW FEATURES:

View File

@ -1,6 +1,6 @@
# Fluentd Config File language support in Atom # Fluentd Configuration language support in Atom
Adds basic syntax highlighting based on the [Sublime Text and TextMate package](https://github.com/adamchainz/fluentd.tmLanguage) to `fluent.conf` files in Atom. Adds basic syntax highlighting based on the [Sublime Text and TextMate package](https://github.com/adamchainz/fluentd.tmLanguage) with some improvements to `fluent.conf` files in Atom.
## License ## License

63
example.fluent.conf Normal file
View File

@ -0,0 +1,63 @@
# Receive events from 24224/tcp
# This is used by log forwarding and the fluent-cat command
<source>
@type forward
port 24224
str_param "foo # This line is converted to "foo\nbar". NL is kept in the parameter
bar"
array_param [
"a", "b"
]
hash_param {
"k":"v",
"k1":10
}
host_param "#{Socket.gethostname}" # host_param is actual hostname like `webserver1`.
env_param "foo-#{ENV["FOO_BAR"]}" # NOTE that foo-"#{ENV["FOO_BAR"]}" doesn't work.
</source>
<source>
@type tail
@label @SYSTEM
</source>
# http://this.host:9880/myapp.access?json={"event":"data"}
<source>
@type http
port 9880
</source>
<filter myapp.access>
@type record_transformer
<record>
host_param "#{Socket.gethostname}"
</record>
</filter>
<match myapp.access>
@type file
path /var/log/fluent/access
</match>
<label @SYSTEM>
<filter var.log.middleware.**>
@type grep
# ...
</filter>
<match **>
@type s3
# ...
</match>
</label>
<system>
# equal to -qq option
log_level error
# equal to --without-source option
without_source
# ...
</system>
# Include config files in the ./config.d directory
@include config.d/*.conf

View File

@ -1,5 +1,5 @@
scopeName: 'source.fluentd' scopeName: 'source.fluentd'
name: 'Fluentd Config File' name: 'Fluentd Configuration'
fileTypes: [ fileTypes: [
'fluent.conf' 'fluent.conf'
] ]

View File

@ -1,6 +1,6 @@
{ {
"name": "language-fluentd", "name": "language-fluentd",
"description": "Fluentd Config File language support in Atom", "description": "Fluentd Configuration language support in Atom",
"version": "1.0.0", "version": "1.0.0",
"engines": { "engines": {
"atom": "*" "atom": "*"