lang: Hook commands

parent 7739df1c
......@@ -564,7 +564,43 @@ Any modification to the own flags table is stored on successful
updater termination or when the script explicitly request it.
Modifications to other scripts' flags tables are not stored.
Hooks
-----
As the hooks are run after all the dependencies have been resolved and
plan has been made, it is no longer possible to call the `Repositor`,
`Package`, `Install` and `Uninstall` commands. These commands may be
used in addition to the rest:
Reboot
~~~~~~
Reboot when
Restarts the OS. It is recommended to use the `reboot` option in the
`Package` command instead, since the updater would know about it in
advance and may, for example, wait for the user to confirm before
doing anything.
The when parameter may be either:
now::
Don't finish the rest of updater, reboot right now. This is
dangerous and should not be used unless necessary, since the rest of
hooks for the given package may be lost. Installation of other
packages will resume after reboot.
eventually::
It will reboot at the end of the updater work.
Rerun
~~~~~
Rerun when
Run the updater once more. The when has a similar meaning as with
`Reboot`. However, it won't resume installation after executing `now`.
TODO
----
* Dependency descriptions
* Hook language
* Shell command
* Uci access
* Allowed libraries
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment