> eval 'opam config env'

Those should be ` (backtick) rather than ' (single quote).

Regards,

Leo