Skip to content

Commit

Permalink
correct syntax for generated readme, update changelog
Browse files Browse the repository at this point in the history
  • Loading branch information
bakito committed Jun 28, 2018
1 parent 29c38a9 commit 1800ecd
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 25 deletions.
14 changes: 8 additions & 6 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,18 @@
# Change Log

## [Unreleased](https://github.com/jenkinsci/badge-plugin/tree/HEAD)

[Full Changelog](https://github.com/jenkinsci/badge-plugin/compare/badge-1.4...HEAD)

## [badge-1.4](https://github.com/jenkinsci/badge-plugin/tree/badge-1.4) (2018-04-04)
[Full Changelog](https://github.com/jenkinsci/badge-plugin/compare/badge-1.3...badge-1.4)
## [badge-1.5](https://github.com/jenkinsci/badge-plugin/tree/badge-1.5) (2018-06-18)
[Full Changelog](https://github.com/jenkinsci/badge-plugin/compare/badge-1.4...badge-1.5)

**Closed issues:**

- No page found 'badge.jelly' for class com.jenkinsci.plugins.badge.action.BadgeSummaryAction [\#6](https://github.com/jenkinsci/badge-plugin/issues/6)

**Merged pull requests:**

- fix one char typo border vs. order [\#9](https://github.com/jenkinsci/badge-plugin/pull/9) ([balihb](https://github.com/balihb))

## [badge-1.4](https://github.com/jenkinsci/badge-plugin/tree/badge-1.4) (2018-04-04)
[Full Changelog](https://github.com/jenkinsci/badge-plugin/compare/badge-1.3...badge-1.4)

**Merged pull requests:**

Expand Down
34 changes: 17 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ This method allows to add build badge icons.
* icon: The icon for this badge
* text: The text for this badge
*/
addBadge(icon, text)
addBadge(icon: <icon>, text: <text>)
/**
* all params
Expand All @@ -36,7 +36,7 @@ addBadge(icon, text)
* id: (optional) The id for this badge. This id can be used to selectively delete badges.
* link: (optional) The link to be added to this badge
*/
addBadge(icon, text, id, link)
addBadge(icon: <icon>, text: <text>, id: <id>, link: <link>)
// addInfoBadge
Expand All @@ -47,7 +47,7 @@ addBadge(icon, text, id, link)
*
* text: The info text for this badge
*/
addInfoBadge(text)
addInfoBadge(text: <text>)
/**
* all params
Expand All @@ -56,7 +56,7 @@ addInfoBadge(text)
* id: (optional) The id for this badge. This id can be used to selectively delete badges.
* link: (optional) The link to be added to this badge
*/
addInfoBadge(text, id, link)
addInfoBadge(text: <text>, id: <id>, link: <link>)
// addWarningBadge
Expand All @@ -67,7 +67,7 @@ addInfoBadge(text, id, link)
*
* text: The text for this warning badge
*/
addWarningBadge(text)
addWarningBadge(text: <text>)
/**
* all params
Expand All @@ -76,7 +76,7 @@ addWarningBadge(text)
* id: (optional) The id for this badge. This id can be used to selectively delete badges.
* link: (optional) The link to be added to this badge
*/
addWarningBadge(text, id, link)
addWarningBadge(text: <text>, id: <id>, link: <link>)
// addErrorBadge
Expand All @@ -87,7 +87,7 @@ addWarningBadge(text, id, link)
*
* text: The text for this error badge
*/
addErrorBadge(text)
addErrorBadge(text: <text>)
/**
* all params
Expand All @@ -96,7 +96,7 @@ addErrorBadge(text)
* id: (optional) The id for this badge. This id can be used to selectively delete badges.
* link: (optional) The link to be added to this badge
*/
addErrorBadge(text, id, link)
addErrorBadge(text: <text>, id: <id>, link: <link>)
```

Expand All @@ -122,7 +122,7 @@ removeBadges()
*
* id: (optional) The id for this badge. This id can be used to selectively delete badges.
*/
removeBadges(id)
removeBadges(id: <id>)
```

Expand All @@ -141,15 +141,15 @@ Puts a badge with custom html
*
* html: The html content to be used for this badge
*/
addHtmlBadge(html)
addHtmlBadge(html: <html>)
/**
* all params
*
* html: The html content to be used for this badge
* id: (optional) The id for this badge. This id can be used to selectively delete badges.
*/
addHtmlBadge(html, id)
addHtmlBadge(html: <html>, id: <id>)
```
## removeHtmlBadges
Expand All @@ -173,7 +173,7 @@ removeHtmlBadges()
*
* id: (optional) The id for this badge. This id can be used to selectively delete badges.
*/
removeHtmlBadges(id)
removeHtmlBadges(id: <id>)
```

Expand All @@ -194,19 +194,19 @@ Puts a badge with a short text
*
* text: The text to add fot this badge
*/
addShortText(text)
addShortText(text: <text>)
/**
* all params
*
* text: The text to add fot this badge
* background: (optional) The background-color for this short text
* border: (optional) The border width for this short text
* borderColor: (optional) The border color for this short text
* borderColor: (optional) The order color for this short text
* color: (optional) The color for this short text
* link: (optional) The link for this short text
*/
addShortText(text, background, border, borderColor, color, link)
addShortText(text: <text>, background: <background>, border: <border>, borderColor: <borderColor>, color: <color>, link: <link>)
```

Expand All @@ -229,7 +229,7 @@ Puts a badge with a short text
*
* icon: The icon for this summary
*/
createSummary(icon)
createSummary(icon: <icon>)
/**
* all params
Expand All @@ -238,7 +238,7 @@ createSummary(icon)
* id: (optional) The id for this badge. This id can be used to selectively delete badges.
* text: (optional) The title text for this summary
*/
createSummary(icon, id, text)
createSummary(icon: <icon>, id: <id>, text: <text>)
def summary = createSummary(icon)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,8 @@ public String interpret(TagNode tagNode, JinjavaInterpreter jinjavaInterpreter)
stream(constructorParams).forEach(sb::append);
sb.append(" */\n");

sb.append(functionName).append("(").append(stream(constructorParams).map(MethodParameter::getName)
sb.append(functionName).append("(")
.append(stream(constructorParams).map(p -> p.getName() + ": <" + p.getName() + ">")
.collect(joining(", "))).append(")\n\n");


Expand All @@ -86,7 +87,7 @@ public String interpret(TagNode tagNode, JinjavaInterpreter jinjavaInterpreter)
sb.append(" */\n");

sb.append(functionName).append("(").append(concat(stream(constructorParams), stream(optionalParameterNames))
.map(MethodParameter::getName).collect(joining(", "))).append(")\n");
.map(p -> p.getName() + ": <" + p.getName() + ">").collect(joining(", "))).append(")\n");
}

} catch (Exception e) {
Expand Down

0 comments on commit 1800ecd

Please sign in to comment.