]> git.lizzy.rs Git - micro.git/blobdiff - runtime/help/plugins.md
Merge branch 'python-highlight-zero' of https://github.com/a11ce/micro into a11ce...
[micro.git] / runtime / help / plugins.md
index 3e651c0151096c15317ff4d7fecb269e27b28678..1818b96bddd4d11f677f4b4439c6556f2d214830 100644 (file)
@@ -43,6 +43,12 @@ are called when certain events happen. Here is the list of callbacks
 which micro defines:
 
 * `init()`: this function should be used for your plugin initialization.
+   This function is called after buffers have been initialized.
+
+* `preinit()`: initialization function called before buffers have been
+   initialized.
+
+* `postinit()`: initialization function called after `init()`.
 
 * `onBufferOpen(buf)`: runs when a buffer is opened. The input contains
    the buffer object.
@@ -279,6 +285,7 @@ The packages and functions are listed below (in Go type signatures):
        string is a word character.
     - `String(b []byte) string`: converts a byte array to a string.
     - `RuneStr(r rune) string`: converts a rune to a string.
+    - `Unzip(src, dest string) error`: unzips a file to given folder.
 
 This may seem like a small list of available functions but some of the objects
 returned by the functions have many methods. The Lua plugin may access any
@@ -352,6 +359,8 @@ strings
 regexp
 errors
 time
+archive/zip
+net/http
 ```
 
 For documentation for each of these functions, see the Go standard
@@ -364,8 +373,6 @@ The following functions are also available from the go-humanize package:
 The `humanize` package exposes:
 * `Bytes`
 * `Ordinal`
-* `Ftoa`
-* `FtoaWithDigits`
 
 ## Adding help files, syntax files, or colorschemes in your plugin
 
@@ -414,7 +421,7 @@ your own plugins.
 Micro also has a built in plugin manager which you can invoke with the
 `> plugin ...` command, or in the shell with `micro -plugin ...`.
 
-For the valid commands you can use, see the `command` help topic.
+For the valid commands you can use, see the `commands` help topic.
 
 The manager fetches plugins from the channels (which is simply a list of plugin
 metadata) which it knows about. By default, micro only knows about the official