gruntjs/grunt — pull request #1061 by jmeas (2014-02-16 23:04:18+00:00)
Title: Replaced regex with path methods for dynamic destPath

The regex used to strip out the extension for dynamic path names removes everything after the first period. This change takes advantage of node path methods instead, which has the effect of only stripping out only things after the last period. For example, given `option.ext === '.min.js'`:

In the old set, `some.long.filename.js` would become `some.min.js` after being parsed by the regex. The new function would return `some.long.filename.min.js`.

I intentionally didn't update the unit tests or anything; I just wanted to see if there was any interest in this change first.

This behavior led to [this issue](https://github.com/gruntjs/grunt-contrib-uglify/issues/157).