Open umlaeute opened 1 year ago
So it would be in the config file:
BASE_IMAGE_RASPBIAN=${BASE_RELEASE_COMPRESS:=yes}
?
I want to assign default values there because its also where people go to look what they can set.
i'm not sure what you mean. your example would
BASE_RELEASE_COMPRESS
to yes
unless it is already set to a non-empty valueBASE_IMAGE_RASPBIAN
to the value of BASE_RELEASE_COMPRESS
(from item1)i guess that mixing of BASE_IMAGE_RASPBIAN
and BASE_RELEASE_COMPRESS
was just a typo.
my line:
: ${BASE_RELEASE_COMPRESS:=yes}
does:
BASE_RELEASE_COMPRESS
to yes
unless it is already set to a non-empty value:
is a nop-command)you can of course use variables on the right-hand term as well:
: ${BASE_IMAGE_PATH:=${DIST_PATH}/image}
but if you feel that this is just busy-work, feel free to ignore (and possibly close) this ticket
the modules are full of default-assignments like so: https://github.com/guysoft/CustomPiOS/blob/f6fea14adfe9febc288bd7c6db8466755a81825f/src/modules/base/config#L13
this is obviously not a bug, but i think the readability could be improved by using POSIX parameter expansion.
the following is equivalent to the test-clause above:
from the bash manpage: