Fixes broken build when building not from git repository

Otherwise, the builded .js files are going to be invalid if building not from git repo.