summaryrefslogtreecommitdiff
path: root/sh/runscript.sh.in
diff options
context:
space:
mode:
authorWilliam Hubbs <williamh@gentoo.org>2011-07-26 12:19:59 -0500
committerWilliam Hubbs <williamh@gentoo.org>2011-07-26 12:19:59 -0500
commitdf1f02ac848a010092df2d3d40b8828051522b4b (patch)
treee9f70164004af1a7f8783e89da6575123edd0b13 /sh/runscript.sh.in
parent863ef36011144a8907359bddc3fe705e5185fd1b (diff)
downloadopenrc-df1f02ac848a010092df2d3d40b8828051522b4b.tar.gz
openrc-df1f02ac848a010092df2d3d40b8828051522b4b.tar.bz2
openrc-df1f02ac848a010092df2d3d40b8828051522b4b.tar.xz
Runscript: print deprecation warning for opts variable
Openrc uses the extra_commands and extra_started_commands variables to list extra commands for services. Also, it supports the opts variable which is used to assist migration from baselayout-1. I am adding this warning to encourage switching from opts to extra_commands/extra_started_commands. I would like to remove support for opts eventually.
Diffstat (limited to 'sh/runscript.sh.in')
-rw-r--r--sh/runscript.sh.in6
1 files changed, 6 insertions, 0 deletions
diff --git a/sh/runscript.sh.in b/sh/runscript.sh.in
index a3f387e..df34b5e 100644
--- a/sh/runscript.sh.in
+++ b/sh/runscript.sh.in
@@ -206,6 +206,12 @@ for _f in $required_files; do
done
unset _f
+if [ -n "$opts" ]; then
+ ewarn "Use of the opts variable is deprecated and will be"
+ ewarn "removed in the future."
+ ewarn "Please use extra_commands or extra_started_commands."
+fi
+
while [ -n "$1" ]; do
# Sepcial case depend
if [ "$1" = depend ]; then