I checked in a .sh file in git repo in ADO service but when I'm running a pipeline, the shell script converts to CRLF format so I'm trying to add a task to convert it back to LF format. Is there a linux command to easily convert it to LF from CRLF? I tried running dos2unix [filename] but no luck.
var script: string = path.join(__dirname, 'test.sh');
const { exec } = require('child_process');
//exec(`sudo apt install dos2unix`)
exec(`chmod +x ${script}`)
exec(`dos2unix ${script}`)