Skip to content

Commit

Permalink
✨ Add link to npm on version badge (#99)
Browse files Browse the repository at this point in the history
  • Loading branch information
Errorname authored and kefranabg committed Aug 2, 2019
1 parent 99dc774 commit fdfe6e3
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 4 deletions.
9 changes: 9 additions & 0 deletions .all-contributorsrc
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,15 @@
"contributions": [
"code"
]
},
{
"login": "Errorname",
"name": "Thibaud Courtoison",
"avatar_url": "https://avatars2.githubusercontent.com/u/6669733?v=4",
"profile": "https://errorna.me",
"contributions": [
"code"
]
}
],
"contributorsPerLine": 7,
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ Feel free to check [issues page](https://github.com/kefranabg/readme-md-generato
<td align="center"><a href="https://github.com/zizizi17"><img src="https://avatars0.githubusercontent.com/u/10571073?v=4" width="75px;" alt="Sasha Semanyuk"/><br /><sub><b>Sasha Semanyuk</b></sub></a><br /><a href="https://github.com/kefranabg/readme-md-generator/commits?author=zizizi17" title="Code">πŸ’»</a></td>
<td align="center"><a href="http://slashgear.github.io/"><img src="https://avatars0.githubusercontent.com/u/6263857?v=4" width="75px;" alt="Antoine Caron"/><br /><sub><b>Antoine Caron</b></sub></a><br /><a href="https://github.com/kefranabg/readme-md-generator/commits?author=Slashgear" title="Code">πŸ’»</a> <a href="https://github.com/kefranabg/readme-md-generator/commits?author=Slashgear" title="Tests">⚠️</a> <a href="#ideas-Slashgear" title="Ideas, Planning, & Feedback">πŸ€”</a></td>
<td align="center"><a href="https://github.com/SwapnikKatkoori"><img src="https://avatars2.githubusercontent.com/u/40907690?v=4" width="75px;" alt="Swapnik Katkoori"/><br /><sub><b>Swapnik Katkoori</b></sub></a><br /><a href="https://github.com/kefranabg/readme-md-generator/commits?author=SwapnikKatkoori" title="Code">πŸ’»</a></td>
<td align="center"><a href="https://errorna.me"><img src="https://avatars2.githubusercontent.com/u/6669733?v=4" width="75px;" alt="Thibaud Courtoison"/><br /><sub><b>Thibaud Courtoison</b></sub></a><br /><a href="https://github.com/kefranabg/readme-md-generator/commits?author=Errorname" title="Code">πŸ’»</a></td>
</tr>
</table>

Expand Down
6 changes: 4 additions & 2 deletions src/__snapshots__/readme.spec.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
exports[`readme buildReadmeContent should return readme default template content 1`] = `
"<h1 align=\\"center\\">Welcome to readme-md-generator πŸ‘‹</h1>
<p>
<img alt=\\"Version\\" src=\\"https://img.shields.io/npm/v/readme-md-generator.svg\\">
<a href=\\"https://www.npmjs.com/package/readme-md-generator\\">
<img alt=\\"Version\\" src=\\"https://img.shields.io/npm/v/readme-md-generator.svg\\">
</a>
<img src=\\"https://img.shields.io/badge/npm-%3E%3D5.5.0-blue.svg\\" />
<img src=\\"https://img.shields.io/badge/node-%3E%3D%209.3.0-blue.svg\\" />
<a href=\\"https://github.com/kefranabg/readme-md-generator#readme\\">
Expand Down Expand Up @@ -77,7 +79,7 @@ _This README was generated with ❀️ by [readme-md-generator](https://github.c

exports[`readme buildReadmeContent should return readme default template no html content 1`] = `
"# Welcome to readme-md-generator πŸ‘‹
![Version](https://img.shields.io/npm/v/readme-md-generator.svg)
[![Version](https://img.shields.io/npm/v/readme-md-generator.svg)](https://www.npmjs.com/package/readme-md-generator)
![Prerequisite](https://img.shields.io/badge/npm-%3E%3D5.5.0-blue.svg)
![Prerequisite](https://img.shields.io/badge/node-%3E%3D%209.3.0-blue.svg)
[![Documentation](https://img.shields.io/badge/documentation-yes-brightgreen.svg)](https://github.com/kefranabg/readme-md-generator#readme)
Expand Down
2 changes: 1 addition & 1 deletion templates/default-no-html.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Welcome to <%= projectName %> πŸ‘‹
<% if (isProjectOnNpm) { -%>
![Version](https://img.shields.io/npm/v/<%= projectName %>.svg)
[![Version](https://img.shields.io/npm/v/<%= projectName %>.svg)](https://www.npmjs.com/package/<%= projectName %>)
<% } -%>
<% if (projectVersion && !isProjectOnNpm) { -%>
![Version](https://img.shields.io/badge/version-<%= projectVersion %>-blue.svg?cacheSeconds=2592000)
Expand Down
4 changes: 3 additions & 1 deletion templates/default.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
<h1 align="center">Welcome to <%= projectName %> πŸ‘‹</h1>
<p>
<% if (isProjectOnNpm) { -%>
<img alt="Version" src="https://img.shields.io/npm/v/<%= projectName %>.svg">
<a href="https://www.npmjs.com/package/<%= projectName %>">
<img alt="Version" src="https://img.shields.io/npm/v/<%= projectName %>.svg">
</a>
<% } -%>
<% if (projectVersion && !isProjectOnNpm) { -%>
<img alt="Version" src="https://img.shields.io/badge/version-<%= projectVersion %>-blue.svg?cacheSeconds=2592000" />
Expand Down

0 comments on commit fdfe6e3

Please sign in to comment.