Skip to content

Commit bc94094

Browse files
committed
Merge pull request ritz078#115 from ritz078/feat/update
fix(npm): Fixed npm dist issue and updated packages
2 parents 3151d7c + f49326b commit bc94094

7 files changed

Lines changed: 1772 additions & 1773 deletions

File tree

Gruntfile.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -240,6 +240,12 @@ module.exports = function (grunt) {
240240
run:true
241241
}
242242
}
243+
},
244+
245+
shell:{
246+
publish : {
247+
command : 'npm publish'
248+
}
243249
}
244250
});
245251

@@ -251,13 +257,7 @@ module.exports = function (grunt) {
251257
grunt.registerTask("dist", ["clean", "eslint", "rollup", "sass", "uglify", "string-replace", "postcss", "copy"]);
252258

253259
grunt.registerTask("release", function (option) {
254-
grunt.task.run(["bump-only:" + option, "dist","conventionalChangelog", "bump-commit"]);
255-
exec('npm publish', function (err, stdout, stderr) {
256-
if (err) {
257-
grunt.fatal('Can not publish to NPM:\n ' + stderr);
258-
}
259-
grunt.log.ok('Published to NPM ');
260-
});
260+
grunt.task.run(["bump-only:" + option, "dist","conventionalChangelog", "bump-commit","shell"]);
261261
});
262262

263263
grunt.registerTask("test",["mocha"]);

bower.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
"version": "3.7.2",
44
"description": "A JavaScript plugin that analyses the string and embeds emojis, media, tweets, code and services.",
55
"main": [
6-
"./dist/embed.min.css",
7-
"./dist/embed.min.js"
6+
"./src/embed.css",
7+
"./src/embed.js"
88
],
99
"authors": [
1010
"Ritesh Kumar <rkritesh078@gmail.com>"

dist/embed.min.js

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

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"emoticon",
1212
"jquery-embed"
1313
],
14-
"main": "./dist/embed.min.js",
14+
"main": "./src/embed.js",
1515
"repository": {
1616
"type": "git",
1717
"url": "https://github.com/ritz078/embed.js.git"

src/embed.js

Lines changed: 1756 additions & 1757 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/twitter/twitter.es6

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,8 @@ export default class Twitter {
5757
}
5858
return [this.output, this.embeds];
5959

60-
} catch (error) {
61-
console.log(error);
60+
} catch (e) {
61+
return [this.output, this.embeds];
6262
}
6363
}
6464
}

0 commit comments

Comments
 (0)