Skip to content

Commit

Permalink
Merge pull request #200 from adobe/checksum
Browse files Browse the repository at this point in the history
feat(build): create hashsums for generated files
  • Loading branch information
trieloff authored Sep 17, 2024
2 parents abdba50 + d13f752 commit 509d4c6
Show file tree
Hide file tree
Showing 7 changed files with 34 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ coverage
.nyc_output/
node_modules/
junit
dist
dist/*.js
tmp
logs
.DS_Store
Expand Down
2 changes: 1 addition & 1 deletion .releaserc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ module.exports = {
}],
"@semantic-release/npm",
["@semantic-release/git", {
"assets": ["package.json", "CHANGELOG.md"],
"assets": ["package.json", "CHANGELOG.md", 'dist/*.md5'],
"message": "chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}"
}],
["@semantic-release/github", {}]
Expand Down
1 change: 1 addition & 0 deletions dist/rum-standalone-404.md5
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
e67cecfc2118c371ee74c394501366ce
1 change: 1 addition & 0 deletions dist/rum-standalone.md5
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
9720190bc018df3c8947391c80d28218
22 changes: 22 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
"mocha": "10.7.3",
"mocha-multi-reporters": "1.5.1",
"rollup": "4.21.3",
"rollup-plugin-checksum": "1.0.1",
"rollup-plugin-cleanup": "3.2.1",
"rollup-plugin-eslint-bundle": "9.0.0",
"semantic-release": "24.1.1"
Expand Down
7 changes: 7 additions & 0 deletions rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@

import cleanup from 'rollup-plugin-cleanup';
import eslint from 'rollup-plugin-eslint-bundle';
import pkg from 'rollup-plugin-checksum';

const checksum = pkg.default;

const banner = `/*
* Copyright 2024 Adobe. All rights reserved.
Expand Down Expand Up @@ -59,5 +62,9 @@ export default [...bundles.map(({ outputFile, source }) => ({
fix: true,
},
}),
checksum({
filename: `${outputFile.split('/').pop()}.md5`,
includeAssets: false,
}),
],
}))];

0 comments on commit 509d4c6

Please sign in to comment.