Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add prepublishOnly script #825

Merged
merged 3 commits into from
Aug 24, 2017
Merged

Add prepublishOnly script #825

merged 3 commits into from
Aug 24, 2017

Conversation

rubenmoya
Copy link
Contributor

Related to: #820

This PR adds a prepublishOnly script which removes unnecessary keys from the package.json.

Feedback is welcome :)

@coveralls
Copy link

Coverage Status

Coverage remained the same at 100.0% when pulling 0d5a99e on rubenmoya:820-add-prepublish-script into 0dea3b7 on developit:master.

@developit developit self-requested a review August 23, 2017 02:24
'eslintConfig'
];

UNNECESSARY_KEYS.forEach(key => delete pkg[key]);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

probably best to keep this as a normal function to support Node 6

@coveralls
Copy link

Coverage Status

Coverage remained the same at 100.0% when pulling 7e40d23 on rubenmoya:820-add-prepublish-script into 0dea3b7 on developit:master.

@developit developit merged commit 5645573 into preactjs:master Aug 24, 2017
@coveralls
Copy link

Coverage Status

Changes Unknown when pulling 5381232 on rubenmoya:820-add-prepublish-script into ** on developit:master**.

@rubenmoya rubenmoya deleted the 820-add-prepublish-script branch August 24, 2017 06:02
rmacklin added a commit to rmacklin/preact that referenced this pull request Aug 26, 2017
This reverts commit 5645573.

Unfortunately, this prepublishOnly script wasn't working properly. The
published package.json was still including the properties that were
supposed to be stripped out by this script, as seen here:
https://unpkg.com/preact@8.2.4/package.json

So instead, to solve preactjs#820, we moved the babel settings to a .babelrc
which is not included in the published package:
d6ab85c

Thus, we can remove this prepublishOnly script
developit pushed a commit that referenced this pull request Aug 26, 2017
This reverts commit 5645573.

Unfortunately, this prepublishOnly script wasn't working properly. The
published package.json was still including the properties that were
supposed to be stripped out by this script, as seen here:
https://unpkg.com/preact@8.2.4/package.json

So instead, to solve #820, we moved the babel settings to a .babelrc
which is not included in the published package:
d6ab85c

Thus, we can remove this prepublishOnly script
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants