title: Getting ##[error] Bash exited with code '1' in an azure-devops pipeline bash cake task with agent Ubuntu-16.04
body: <p>We have a pipeline that runs on a linux agent Ubuntu-16.04 with image version 20200119.1 </p>
  
  <p><a href="https://github.com/actions/virtual-environments/blob/master/images/linux/Ubuntu1604-README.md" rel="nofollow noreferrer">https://github.com/actions/virtual-environments/blob/master/images/linux/Ubuntu1604-README.md</a></p>
  
  <p>It runs a bash cake task and returns </p>
  
  <pre><code>Restoring NuGet package Cake.0.36.0.
    GET https://api.nuget.org/v3-flatcontainer/cake/0.36.0/cake.0.36.0.nupkg
    OK https://api.nuget.org/v3-flatcontainer/cake/0.36.0/cake.0.36.0.nupkg 12ms
  Installing Cake 0.36.0.
  Adding package 'Cake.0.36.0' to folder '/home/vsts/work/1/s/build/tools'
  Added package 'Cake.0.36.0' to folder '/home/vsts/work/1/s/build/tools'
  Error: The assembly name is invalid.
  
  ##[error]Bash exited with code '1'.
  Finishing: Bash Script
  </code></pre>
  
  <p>I think the issue is related with this one <a href="https://stackoverflow.com/questions/59836223/cake-on-osx-fails-with-error-the-assembly-name-is-invalid">Cake on OSX fails with &quot;error: the assembly name is invalid&quot;</a></p>
  
  <p>So basically now the agent has Mono 6.8.0 and it runs into this problem. Is there any way to fix it?</p>