[Toaster] [PATCH] toaster: Improve messaging when conf file not found

Brian Avery avery.brian at gmail.com
Fri Nov 6 10:15:07 PST 2015


2 things.
1) encouraging people to modify the script scares me. these variables
are better/more safely set in the environment.  we should probably do
something like:
echo " "$TOASTER_CONF configuration file not found. Set the
TOASTER_CONF variable in your env and export it i.e. $>export
TOASTER_CONF=/home/me/mytoasterconf.json"

2) I switched (again) the way toasterconf's are done in response to a
valid Khem/Paul complaint wrt the fact that we should use the same
template approach that bb uses to decide between meta/conf and
meta-yocto/conf.
https://lists.yoctoproject.org/pipermail/toaster/2015-November/003268.html

-b

On Fri, Nov 6, 2015 at 4:25 AM, Belen Barros Pena
<belen.barros.pena at linux.intel.com> wrote:
> From: Belen Barros Pena <belen.barros.pena at intel.com>
>
> If the toasterconf.json file specified in TOASTER_CONF
> does not exist, you get a message asking you to set
> TOASTER_CONF to the path of a valid configuration file.
>
> The message, however, doesn't tell you where to set
> TOASTER_CONF. Specify that you set TOASTER_CONF in the
> bitbake/bin/toaster script to save people the proverbial
> grepping.
>
> Signed-off-by: Belen Barros Pena <belen.barros.pena at intel.com>
> ---
>  bitbake/bin/toaster | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/bitbake/bin/toaster b/bitbake/bin/toaster
> index 2c3432c..db02bc3 100755
> --- a/bitbake/bin/toaster
> +++ b/bitbake/bin/toaster
> @@ -200,7 +200,7 @@ if [ "$TOASTER_CONF" = "" ]; then
>      export TOASTER_CONF=$(python -c "import os; print os.path.realpath('$TOASTER_CONF')")
>  fi
>  if [ ! -f $TOASTER_CONF ]; then
> -    echo "$TOASTER_CONF configuration file not found. set TOASTER_CONF to specify a path"
> +    echo "$TOASTER_CONF configuration file not found. Set the TOASTER_CONF variable in the \"bitbake/bin/toaster\" script to specify the path to a Toaster configuration file."
>      [ "$TOASTER_MANAGED" = '1' ] && exit 1 || return 1
>  fi
>  # this defines the dir toaster will use for
> --
> 2.4.9 (Apple Git-60)
>
> --
> _______________________________________________
> toaster mailing list
> toaster at yoctoproject.org
> https://lists.yoctoproject.org/listinfo/toaster


More information about the toaster mailing list