Skip to content

Commit

Permalink
fix(build): add asset to github release (#330)
Browse files Browse the repository at this point in the history
Ref. https://dintero.slack.com/archives/G7ESUNQ0Z/p1708678043060989

Change configuration for semantic-release. With these changes we

change order of npm and github plugins (not sure if needed but it matches the order of when they have an effect better)
add npm plugin configuration so that the tarball from npm pack is added to the dist folder
add github plugin configuration with an  asset entry that takes all tarballs in the dist folder
See related example in the docs for the npm plugin here https://github.com/semantic-release/npm?tab=readme-ov-file#examples

Docs:

https://github.com/semantic-release/npm
https://github.com/semantic-release/github
  • Loading branch information
svnv authored Feb 26, 2024
1 parent bd2c51f commit d0a1d20
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions .releaserc.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,20 @@
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/github",
"@semantic-release/npm"

[
"@semantic-release/npm",
{
"npmPublish": true,
"pkgRoot": ".",
"tarballDir": "dist"
}
],
[
"@semantic-release/github",
{
"assets": "dist/*.tgz"
}
]
]
}

0 comments on commit d0a1d20

Please sign in to comment.