It seems that the .js and .map files that you want to ignore git are already in the index. You must tell git to cancel these files:
git rm --cached TypeScriptTest.Content/Scripts/*.js git rm --cached TypeScriptTest.Content/Scripts/*.js.map
Quote from GitHub's Help on Ignoring Files :
Note that git will not ignore a file that has already been tracked until a rule has been added to this file to ignore it.
source share