Copy audio-related files into js/ instead of symlinking them (#1456)

This adds a new copy:deps task into the overall default task, and it
needs to be run before running the product for the first time, and after
upgrading audio-related deps.

FREEBIE
This commit is contained in:
Scott Nonnenberg 2017-09-11 09:47:37 -07:00
parent 272955b9d6
commit 02571b7ae9
No known key found for this signature in database
GPG key ID: A4931C09644C654B
3 changed files with 46801 additions and 4 deletions

View file

@ -126,6 +126,15 @@ module.exports = function(grunt) {
]
},
copy: {
deps: {
files: [{
src: 'components/mp3lameencoder/lib/Mp3LameEncoder.js',
dest: 'js/Mp3LameEncoder.min.js'
}, {
src: 'components/webaudiorecorder/lib/WebAudioRecorderMp3.js',
dest: 'js/WebAudioRecorderMp3.js'
}],
},
res: {
files: [{ expand: true, dest: 'dist/', src: ['<%= dist.res %>'] }],
},
@ -491,9 +500,9 @@ module.exports = function(grunt) {
grunt.registerTask('tx', ['exec:tx-pull', 'locale-patch']);
grunt.registerTask('dev', ['default', 'connect', 'watch']);
grunt.registerTask('test', ['jshint', 'jscs', 'unit-tests']);
grunt.registerTask('copy_dist', ['gitinfo', 'copy']);
grunt.registerTask('copy_dist', ['gitinfo', 'copy:res', 'copy:src']);
grunt.registerTask('date', ['gitinfo', 'getExpireTime']);
grunt.registerTask('prep-release', ['gitinfo', 'clean-release', 'fetch-release']);
grunt.registerTask('default', ['concat', 'sass', 'date']);
grunt.registerTask('default', ['concat', 'copy:deps', 'sass', 'date']);
};