Skip to content

Commit

Permalink
feat: Support travis-ci shields.io badge
Browse files Browse the repository at this point in the history
  • Loading branch information
Alorel committed Aug 9, 2018
1 parent 4d8e221 commit c1531ff
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/prepare/setReadmeVersions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,14 @@ export async function setReadmeVersions(_cfg: Conf, ctx: Context): Promise<void>
}

const replacements: any[][] = [
[/\?branch=([a-z0-9.\-_]+)/ig, `?branch=${ctx.nextRelease.version}`]
[
/\?branch=([a-z0-9.\-_]+)/ig,
`?branch=${ctx.nextRelease.version}`
],
[
/img\.shields\.io\/travis(\/com)?\/([a-z0-9-_.]+)\/([a-z0-9-_.]+)\/([a-z0-9-_.]+)\.([a-z]{2,4})/ig,
'img.shields.io/travis$1/$2/$3/my-branch.$5'
]
];

log('Applying versions to README');
Expand Down

0 comments on commit c1531ff

Please sign in to comment.