Hi!

On 2023-10-11 11:08, Raphaƫl Hertzog wrote:
> it would be nice if sbuild supported the --env=VAR=VALUE command line
> option like autopkgtest:
> 
>        --env=VAR=value
>             Set arbitrary environment variable in the build and test.
>             Can be specified multiple times.

As a suggestion for an alternative approach, instead of specifying both
the variable name and its value on the CLI we could add support for
appending values to $environment_filter, ie: specify which variables
should be whitelisted.

Something like:
  --allow-var=FOO --allow-var=BAR

Resulting in:
  $environment_filter = [Dpkg::BuildInfo::get_build_env_allowed(), 'FOO', 
'BAR'];

Either way, definitely a useful feature!

Reply via email to