Should this command add a remote named mega2 with the correct credentials to use? rclone config create ${name} ${type} --mega-pass=${pass} --mega-user=${user}
All it seemse to do is add the below entry in my conf:
Would be field value for each parameter you want to pass in so something like this.
rclone config create mega2 mega password password user user
Remote config
--------------------
[mega2]
type = mega
user = user
password = password
--------------------