Skip to content

Commit 2ff5817

Browse files
committed
feat(release): added grunt release to automate publishing
1 parent c58d4b8 commit 2ff5817

5 files changed

Lines changed: 18 additions & 3 deletions

File tree

Gruntfile.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,8 +177,9 @@ rollup: {
177177
grunt.loadNpmTasks("grunt-contrib-sass");
178178
grunt.loadNpmTasks("grunt-contrib-uglify");
179179
grunt.loadNpmTasks("grunt-contrib-connect");
180-
grunt.loadNpmTasks("grunt-rollup")
181-
grunt.loadNpmTasks("grunt-eslint")
180+
grunt.loadNpmTasks("grunt-rollup");
181+
grunt.loadNpmTasks("grunt-eslint");
182+
grunt.loadNpmTasks('grunt-release');
182183

183184
grunt.registerTask("default", ["eslint","rollup", "sass", "connect", "watch"]);
184185
grunt.registerTask("build", ["clean", "build-emoji","eslint", "rollup", "uglify", "postcss"]);

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@
5757
"grunt-contrib-watch": "^0.6.1",
5858
"grunt-eslint": "^17.3.1",
5959
"grunt-postcss": "^0.7.1",
60+
"grunt-release": "^0.13.0",
6061
"grunt-retinafy": "^0.1.5",
6162
"grunt-rollup": "^0.6.1",
6263
"grunt-spritesmith": "^6.1.0",

src/embed.js

Lines changed: 7 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/embed.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/js/modules/helper.es6

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,12 @@ var helper = {
110110
}
111111
},
112112

113+
/**
114+
* A helper function for inline embedding
115+
* @param _this
116+
* @param urlToText
117+
* @returns {*}
118+
*/
113119
async inlineEmbed(_this, urlToText){
114120
if (!regeneratorRuntime) return _this.output;
115121
let regexInline = _this.options.link ? new RegExp(`([^>]*${_this.regex.source})<\/a>`, 'gi') : new RegExp(`([^\\s]*${_this.regex.source})`, 'gi');

0 commit comments

Comments
 (0)