Unable to build extension

I created a new extension scaffolding using cookiecutter and for the first few cycles, I was able to build the extension code successfully. But I later checked-in the code to my source control system and thereafter I am not able to build the extension. I get the following error:
Error: EPERM: operation not permitted, open 'C:\Rakesh\jupyterlab-extension\labext1\labext1\labextension\package.json'
The file mentioned in the above error is not checked-in. When I clean the project using jlpm clean:all and then build, this file is created but it’s created as read-only due to which the build fails. Can someone help me fix this issue?