Skip to content
This repository was archived by the owner on Feb 18, 2022. It is now read-only.

Commit 1ff68d9

Browse files
authored
Merge pull request #224 from roger2hk/master
Fix to avoid bower install warning message related to "main" field containing minified files in bower.json
2 parents 027d596 + 1410d2d commit 1ff68d9

File tree

4 files changed

+25
-4
lines changed

4 files changed

+25
-4
lines changed

Gruntfile.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@
2020
, cssmin = require('./tasks/cssmin')(banner, grunt)
2121
, connect = require('./tasks/connect')(grunt)
2222
, watch = require('./tasks/watch')(grunt)
23-
, concurrent = require('./tasks/concurrent')(grunt);
23+
, concurrent = require('./tasks/concurrent')(grunt)
24+
, copy = require('./tasks/copy')(grunt);
2425

2526
grunt.initConfig({
2627
'pkg': grunt.file.readJSON('package.json'),
@@ -32,7 +33,8 @@
3233
'cssmin': cssmin,
3334
'connect': connect,
3435
'watch': watch,
35-
'concurrent': concurrent
36+
'concurrent': concurrent,
37+
'copy': copy
3638
});
3739

3840
grunt.registerTask('default', [
@@ -48,6 +50,7 @@
4850

4951
grunt.registerTask('prod', [
5052
'lint',
53+
'copy:non-minified',
5154
'cssmin',
5255
'uglify'
5356
]);

bower.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616
],
1717
"license": "MIT",
1818
"main": [
19-
"./dist/angular-datepicker.min.css",
20-
"./dist/angular-datepicker.min.js",
19+
"./dist/angular-datepicker.css",
20+
"./dist/angular-datepicker.js",
2121
"./dist/angular-datepicker.sourcemap.map"
2222
],
2323
"homepage": "http://720kb.github.io/angular-datepicker",

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
"grunt": "*",
2828
"grunt-concurrent": "*",
2929
"grunt-contrib-connect": "*",
30+
"grunt-contrib-copy": "*",
3031
"grunt-contrib-csslint": "*",
3132
"grunt-contrib-cssmin": "*",
3233
"grunt-contrib-uglify": "*",

tasks/copy.js

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
/*global module, require*/
2+
(function setUp(module, require) {
3+
'use strict';
4+
5+
module.exports = function exportingFunction(grunt) {
6+
7+
grunt.loadNpmTasks('grunt-contrib-copy');
8+
return {
9+
'non-minified': {
10+
'files': [
11+
{ expand: true, flatten: true, src: ['<%= confs.css %>/**/*.css'], dest: '<%= confs.dist %>/', filter: 'isFile' },
12+
{ expand: true, flatten: true, src: ['<%= confs.js %>/**/*.js'], dest: '<%= confs.dist %>/', filter: 'isFile' },
13+
]
14+
}
15+
};
16+
};
17+
}(module, require));

0 commit comments

Comments
 (0)