DMAP-45 - Prepare BrowserMap module for ASF releases
* separated build artifacts into source artifact and dist artitfact
* moved dependencies license information from NOTICE to LICENSE
* improved package.json description file
* provided rat.exclude file for checking source files
git-svn-id: https://svn.apache.org/repos/asf/incubator/devicemap/trunk/browsermap/trunk@1610949 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/Gruntfile.js b/Gruntfile.js
index 1055899..b9e609d 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -58,7 +58,8 @@
files: [
{src: ['src/main/js/*.js'], dest: 'target/libs/browsermap/', expand: true, flatten: true},
{cwd: 'src/main/resources/demo/', src: ['**'], dest: 'target/demo/', expand: true},
- {cwd: 'src/main/lib/', src: ['**'], dest: 'target/libs/externals/', expand: true}
+ {cwd: 'src/main/lib/', src: ['**'], dest: 'target/libs/externals/', expand: true},
+ {src: ['NOTICE'], dest: 'target/', expand: true}
]
},
minified: {
@@ -94,28 +95,39 @@
}
},
compress: {
- browsermap: {
+ source: {
options: {
archive: 'target/browsermap-<%= pkg.version %>-incubating.tar.gz',
mode: 'tgz',
pretty: true
},
files: [
- {src: ['LICENSE', 'NOTICE', 'README.md', 'DISCLAIMER'], dest: 'browsermap-<%= pkg.version %>-incubating/'},
- {cwd: 'target/demo', src: ['**'], dest: 'browsermap-<%= pkg.version %>-incubating/demo/', expand: true},
- {cwd: 'target/doc/', src: ['**'], dest: 'browsermap-<%= pkg.version %>-incubating/doc/', expand: true},
- {cwd: 'target/libs/min/', src: ['*.js'], dest: 'browsermap-<%= pkg.version %>-incubating/dist/', expand: true},
- {cwd: 'target/report', src: ['**'], dest: 'browsermap-<%= pkg.version %>-incubating/reporting/', expand: true},
-
// the following entries provide the source files in the archive
- {cwd: 'src/', src: ['**/*.js'], dest: 'browsermap-<%= pkg.version %>-incubating/source/src/', expand: true},
- {cwd: 'src/', src: ['**/*.css'], dest: 'browsermap-<%= pkg.version %>-incubating/source/src/', expand: true},
- {cwd: 'src/', src: ['**/*.html'], dest: 'browsermap-<%= pkg.version %>-incubating/source/src/', expand: true},
+ {cwd: 'src/', src: ['**/*.js'], dest: 'browsermap-<%= pkg.version %>-incubating/src/', expand: true},
+ {cwd: 'src/', src: ['**/*.css'], dest: 'browsermap-<%= pkg.version %>-incubating/src/', expand: true},
+ {cwd: 'src/', src: ['**/*.html'], dest: 'browsermap-<%= pkg.version %>-incubating/src/', expand: true},
+ {cwd: 'target/', src: ['NOTICE'], dest: 'browsermap-<%= pkg.version %>-incubating/', expand: true},
{
- src: ['.gitignore', '.travis.yml', 'Gruntfile.js', 'package.json', 'README.md', 'LICENSE', 'NOTICE', 'DISCLAIMER'],
- dest: 'browsermap-<%= pkg.version %>-incubating/source/'
+ src: [
+ '.gitignore', '.travis.yml', 'Gruntfile.js', 'package.json', 'README.md', 'LICENSE', 'DISCLAIMER', 'rat.exclude'
+ ],
+ dest: 'browsermap-<%= pkg.version %>-incubating/'
},
- {src: ['ci/**'], dest: 'browsermap-<%= pkg.version %>-incubating/source/'}
+ {src: ['ci/**'], dest: 'browsermap-<%= pkg.version %>-incubating/'}
+ ]
+ },
+ dist: {
+ options: {
+ archive: 'target/browsermap-<%= pkg.version %>-incubating-dist.tar.gz',
+ mode: 'tgz',
+ pretty: true
+ },
+ files: [
+ {src: ['LICENSE', 'README.md', 'DISCLAIMER'], dest: 'browsermap-<%= pkg.version %>-incubating-dist/'},
+ {cwd: 'target/demo', src: ['**'], dest: 'browsermap-<%= pkg.version %>-incubating-dist/demo/', expand: true},
+ {cwd: 'target/doc/', src: ['**'], dest: 'browsermap-<%= pkg.version %>-incubating-dist/doc/', expand: true},
+ {cwd: 'target/', src: ['NOTICE'], dest: 'browsermap-<%= pkg.version %>-incubating-dist/', expand: true},
+ {cwd: 'target/libs/min/', src: ['*.js'], dest: 'browsermap-<%= pkg.version %>-incubating-dist/', expand: true}
]
}
},
@@ -148,7 +160,7 @@
]
},
sourcetemplates: {
- files: ['target/libs/browsermap/bmap.js']
+ files: ['target/libs/browsermap/bmap.js', 'target/NOTICE']
}
});
@@ -222,5 +234,5 @@
grunt.registerTask('coverage', ['qunit-cov']);
grunt.registerTask('test', ['jshint', 'karma:continuous', 'qunit']);
grunt.registerTask('package', ['clean', 'test', 'copy:browsermap', 'sourcetemplates', 'minify', 'copy:minified', 'demo', 'jsdoc',
- 'compress']);
+ 'compress:source', 'compress:dist']);
};
diff --git a/LICENSE b/LICENSE
index d9a10c0..a945cde 100644
--- a/LICENSE
+++ b/LICENSE
@@ -174,3 +174,71 @@
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
+
+The following subcomponents or dependencies use a different license:
+
+Modernizr
+
+ Copyright (c) 2009–2013
+
+ Permission is hereby granted, free of charge, to any person obtaining a copy
+ of this software and associated documentation files (the "Software"), to deal
+ in the Software without restriction, including without limitation the rights
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ copies of the Software, and to permit persons to whom the Software is
+ furnished to do so, subject to the following conditions:
+
+ The above copyright notice and this permission notice shall be included in
+ all copies or substantial portions of the Software.
+
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ THE SOFTWARE.
+
+matchMedia.js
+
+ Copyright (c) 2012 Scott Jehl
+
+ Permission is hereby granted, free of charge, to any person obtaining a copy
+ of this software and associated documentation files (the "Software"), to deal
+ in the Software without restriction, including without limitation the rights
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ copies of the Software, and to permit persons to whom the Software is
+ furnished to do so, subject to the following conditions:
+
+ The above copyright notice and this permission notice shall be included in
+ all copies or substantial portions of the Software.
+
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ THE SOFTWARE.
+
+qunit
+
+ Copyright (c) 2012 John Resig, Jörn Zaefferer
+
+ Permission is hereby granted, free of charge, to any person obtaining a copy
+ of this software and associated documentation files (the "Software"), to deal
+ in the Software without restriction, including without limitation the rights
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ copies of the Software, and to permit persons to whom the Software is
+ furnished to do so, subject to the following conditions:
+
+ The above copyright notice and this permission notice shall be included in
+ all copies or substantial portions of the Software.
+
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ THE SOFTWARE.
diff --git a/NOTICE b/NOTICE
index b9b3e08..bb83552 100644
--- a/NOTICE
+++ b/NOTICE
@@ -1,53 +1,9 @@
Apache DeviceMap
-Copyright 2013 The Apache Software Foundation
+Copyright <%= grunt.template.today('yyyy') %> The Apache Software Foundation
This product includes software developed at
The Apache Software Foundation (http://www.apache.org/).
Apache DeviceMap includes subcomponents with separate copyright notices and
license terms. Your use of these subcomponents is subject to the terms
-and conditions of the following licenses.
-
-Modernizr
-
- Copyright (c) 2009–2013
-
- Permission is hereby granted, free of charge, to any person obtaining a copy
- of this software and associated documentation files (the "Software"), to deal
- in the Software without restriction, including without limitation the rights
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- copies of the Software, and to permit persons to whom the Software is
- furnished to do so, subject to the following conditions:
-
- The above copyright notice and this permission notice shall be included in
- all copies or substantial portions of the Software.
-
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- THE SOFTWARE.
-
-matchMedia.js
-
- Copyright (c) 2012 Scott Jehl
-
- Permission is hereby granted, free of charge, to any person obtaining a copy
- of this software and associated documentation files (the "Software"), to deal
- in the Software without restriction, including without limitation the rights
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- copies of the Software, and to permit persons to whom the Software is
- furnished to do so, subject to the following conditions:
-
- The above copyright notice and this permission notice shall be included in
- all copies or substantial portions of the Software.
-
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- THE SOFTWARE.
+and conditions of those licenses.
diff --git a/package.json b/package.json
index bc93324..41e309b 100644
--- a/package.json
+++ b/package.json
@@ -1,22 +1,31 @@
{
- "name": "BrowserMap",
- "version": "1.4.1",
+ "name": "browsermap",
+ "title": "Apache DeviceMap BrowserMap",
+ "version": "1.4.1-rc1",
"description": "YABFDL - yet another browser features detection library",
- "main": "index.js",
"scripts": {
"test": "grunt test"
},
- "repository": {
+ "homepage" : "http://incubator.apache.org/devicemap/",
+ "repository" : {
"type": "git",
"url": "git@github.com:apache/devicemap-browsermap.git"
},
"author": {
"name": "The Apache DeviceMap team"
},
+ "bugs": {
+ "url" : "https://issues.apache.org/jira/browse/DMAP"
+ },
"license": {
"type": "Apache License",
"url": "http://www.apache.org/licenses/LICENSE-2.0"
},
+ "keywords" : [
+ "devicemap",
+ "browser features detection",
+ "probing"
+ ],
"readmeFilename": "README.md",
"devDependencies": {
"grunt": "~0.4.1",
diff --git a/rat.exclude b/rat.exclude
new file mode 100644
index 0000000..3bb1c62
--- /dev/null
+++ b/rat.exclude
@@ -0,0 +1,6 @@
+README.md
+matchMedia*
+modernizr*
+qunit*
+.gitignore
+rat.exclude