Skip to content

Commit

Permalink
Remove "postinstall" script from package.json to fix #1318
Browse files Browse the repository at this point in the history
Update package-lock.json's "hasInstallScript" field.
  • Loading branch information
ronyeh committed Feb 2, 2022
1 parent d467208 commit a23f63c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 9 deletions.
13 changes: 7 additions & 6 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -722,7 +722,7 @@ module.exports = (grunt) => {
// https://github.com/0xfe/vexflow/wiki/Build,-Test,-Release#publish-manually-to-npm-and-github
grunt.registerTask('release', 'Produce the complete build. Release to npm and GitHub.', function (...args) {
if (!process.env.GITHUB_TOKEN) {
console.warn(
console.log(
'GITHUB_TOKEN environment variable is missing.\n' +
'You can manually release to GitHub at https://github.com/0xfe/vexflow/releases/new\n' +
'Or use the GitHub CLI:\n' +
Expand All @@ -736,14 +736,14 @@ module.exports = (grunt) => {
// https://github.com/release-it/release-it
// https://github.com/release-it/release-it/blob/master/config/release-it.json
const options = {
// verbose: 1, // See the output of each hook.
verbose: 1, // See the output of each hook.
// verbose: 2, // Only for debugging.
hooks: {
'before:init': ['grunt clean'],
'before:init': ['npx patch-package', 'grunt clean'],
'after:bump': ['grunt', 'echo Adding build/ folder...', 'git add -f build/'],
'after:npm:release': ['echo Published to npm.'],
'after:git:release': ['echo Committed to git repository.'],
'after:github:release': ['echo Released to GitHub.'],
'after:npm:release': [],
'after:git:release': [],
'after:github:release': [],
'after:release': ['echo Successfully released ${name} ${version} to https://github.com/${repo.repository}'],
},
git: {
Expand Down Expand Up @@ -797,6 +797,7 @@ module.exports = (grunt) => {
});

release(options).then((output) => {
console.log(output);
try {
// If the build/ folder is currently checked in to the repo, we remove it.
const hideOutput = { stdio: 'pipe' }; // Hide the output of the following two execSync() calls.
Expand Down
1 change: 0 additions & 1 deletion package-lock.json

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

3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -121,8 +121,7 @@
"test": "grunt test",
"reference": "grunt reference",
"test:reference": "grunt test:reference",
"test:reference:cache": "grunt test:reference:cache",
"postinstall": "patch-package"
"test:reference:cache": "grunt test:reference:cache"
},
"homepage": "https://vexflow.com/",
"keywords": [
Expand Down

0 comments on commit a23f63c

Please sign in to comment.