I recommend that you have two scripts:
{
...
"lint:check": "next lint",
"lint:fix": "next lint --fix"
},
P.S: Concatenating the commands next lint && next lint --fix
will not work because the first one returns the files that have errors, therefore it stops the execution.