Updating logger to support different types (#452) fixes #437

* Updating logger to support different types

* changing to ouptut info by default

* updating docs with air

* adding air modify definition
This commit is contained in:
Ghoulboy authored and GitHub committed 2020-09-07 15:19:28 -03:00
1 parent d072e4946a
commit 26169f042e
5 files changed
+63 -14

No files matched your search

+10 -5
View File
@@ -245,13 +245,18 @@ Example usages:
// not a problem in apps
</pre>
### `logger(expr)`
### `logger(msg), logger(type, msg)`
Prints the message to system logs, and not to chat.
Prints the message to system logs, and not to chat. By default prints an info, unless you specify otherwise in the `type` parameter.
### read_file(resource, type)
### delete_file(resource, type)
### write_file(resource, type, data, ...)
Available output types:
`'debug'`, `'warn'`, `'fatal'`, `'info'` and `'error'`
### `read_file(resource, type)`
### `delete_file(resource, type)`
### `write_file(resource, type, data, ...)`
With the specified `resource` in the scripts folder, of a specific `type`, writes/appends `data` to it, reads its
content, or deletes the resource.