Skip to content
This repository was archived by the owner on Apr 14, 2021. It is now read-only.

Commit dbbcc68

Browse files
committed
adding grunt task to uglify to Intl.min.js preserving the license. adding contributing steps. renaming the npm pkg since a dot cannot be part of the npm module name
1 parent 4bf2d84 commit dbbcc68

File tree

5 files changed

+68
-2
lines changed

5 files changed

+68
-2
lines changed

.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,6 @@ cldr/
99

1010
# d8 artifact
1111
.d8_history
12+
13+
# npm
14+
node_modules

CONTRIBUTING.md

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
Contributing Code to `Intl.js`
2+
------------------------------
3+
4+
Dev mode installation
5+
---------------------
6+
7+
To install the dependencies:
8+
9+
npm install
10+
11+
To run the unit tests:
12+
13+
npm test
14+
15+
To build files:
16+
17+
npm run build
18+
19+
Release checklist
20+
-----------------
21+
22+
* build all files using `npm run build`
23+
* verify that [README.md] is updated
24+
* bump the version in [package.json]
25+
* commit to master
26+
* push to npm using `npm publish`
27+
* create a [new release] entry including the tag for the new version, being sure to document any deprecations
28+
29+
[README.md]: https://github.com/andyearnshaw/Intl.js/blob/master/README.md
30+
[package.json]: https://github.com/andyearnshaw/Intl.js/blob/master/package.json
31+
[new release]: https://github.com/andyearnshaw/Intl.js/releases/new

Gruntfile.js

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
module.exports = function (grunt) {
2+
3+
grunt.initConfig({
4+
uglify: {
5+
options: {
6+
preserveComments: 'some'
7+
},
8+
my_target: {
9+
files: {
10+
'Intl.min.js': ['Intl.js']
11+
}
12+
}
13+
}
14+
});
15+
16+
grunt.loadNpmTasks('grunt-contrib-uglify');
17+
grunt.registerTask('default', ['uglify']);
18+
19+
};

README.md

+7
Original file line numberDiff line numberDiff line change
@@ -90,3 +90,10 @@ in the [tools](https://github.com/andyearnshaw/Intl.js/tree/master/tools) folder
9090

9191
Collation data isn't currently present since the `Intl.Collator` implementation isn't
9292
finished.
93+
94+
Contribute
95+
----------
96+
97+
See the [CONTRIBUTING file][] for info.
98+
99+
[CONTRIBUTING file]: https://github.com/andyearnshaw/Intl.js/blob/master/CONTRIBUTING.md

package.json

+8-2
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,19 @@
11
{
2-
"name": "Intl.js",
2+
"name": "intl-polyfill",
33
"version": "0.0.1",
44
"description": "polyfill the ECMA-402 Intl API (except collation)",
55
"main": "Intl.js",
66
"directories": {
77
"test": "tests"
88
},
9+
"devDependencies": {
10+
"grunt": "~0.4.2",
11+
"grunt-cli": "~0.1.11",
12+
"grunt-contrib-uglify": "0.2.7"
13+
},
914
"scripts": {
10-
"test": "cd tests && ./run402"
15+
"test": "cd tests && ./run402",
16+
"build": "grunt"
1117
},
1218
"repository": {
1319
"type": "git",

0 commit comments

Comments
 (0)