From 6d7d21655c0bf9b7868353898c7d2c88d18ed172 Mon Sep 17 00:00:00 2001 From: Alexei Chekulaev Date: Wed, 28 Jun 2017 23:16:08 -0400 Subject: [PATCH] Fix README. Fix and improve hook exmaple descriptions. --- example/README.md | 2 +- example/example.post-install | 5 +++-- example/example.post-uninstall | 5 +++-- example/example.pre-install | 8 ++++---- example/example.pre-uninstall | 7 +++++-- 5 files changed, 16 insertions(+), 11 deletions(-) diff --git a/example/README.md b/example/README.md index 13ef495..96f7b40 100644 --- a/example/README.md +++ b/example/README.md @@ -8,7 +8,7 @@ Addon name is the name of the folder containing it. In this case addon name is ` ## Required files -Each addon should have a main script that is named as the addon. In this case the main script name is `example`. It should be located in this directory. +Each addon should have a main script that is named as the addon. In this case the main script name is `example`. It should be located in the addon root directory. ## Optional files diff --git a/example/example.post-install b/example/example.post-install index aeb0ea3..28756ad 100644 --- a/example/example.post-install +++ b/example/example.post-install @@ -1,4 +1,5 @@ #!/bin/bash -echo "Post-install script to perform desired tasks after installation..." -sleep 1 \ No newline at end of file +echo " This is a post-install script output." +echo " Use it to perform additional tasks after addon installation." +sleep 1 diff --git a/example/example.post-uninstall b/example/example.post-uninstall index 0355a7e..b5913b6 100644 --- a/example/example.post-uninstall +++ b/example/example.post-uninstall @@ -1,4 +1,5 @@ #!/bin/bash -echo "Post-uninstall script to perform a cleanup..." -sleep 2 \ No newline at end of file +echo " This is an example post-uninstall script to perform a cleanup..." +echo " Addon code is gone by this moment." +sleep 2 diff --git a/example/example.pre-install b/example/example.pre-install index 05b7815..54e1bf1 100644 --- a/example/example.pre-install +++ b/example/example.pre-install @@ -1,8 +1,8 @@ #!/bin/bash -echo "Pre-install script" +echo " This is an example pre-install script output..." sleep 1 -ehco "Check for dependencies or pre-requisites..." +echo " Use pre-install shook to check for dependencies or pre-requisites..." +sleep 2 +echo " If exit code is non-zero, then addon installation will not continue." sleep 2 -echo "If exit code if non-zero the installation will not continue." -sleep 2 \ No newline at end of file diff --git a/example/example.pre-uninstall b/example/example.pre-uninstall index 3d23208..4861cde 100644 --- a/example/example.pre-uninstall +++ b/example/example.pre-uninstall @@ -1,4 +1,7 @@ #!/bin/bash -echo "Pre-uninstall to ask for additional confirmation or warn about outcome..." -sleep 2 \ No newline at end of file +echo " This is an example pre-uninstall hook output" +echo " Use this hook to ask for additional confirmations or to warn about outcome..." +sleep 2 +echo " If exit code will be non-zero then uninstallation will not happen..." +sleep 1