Skip to content
This repository has been archived by the owner on Jul 3, 2019. It is now read-only.

Add option to extract package.json as-is. #166

Open
wants to merge 1 commit into
base: latest
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion extract.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ function extract (spec, dest, opts) {
return tryExtract(spec, stream, dest, opts)
})
.then(() => {
if (!opts.resolved) {
if (!opts.resolved && !opts.unmodified) {
const pjson = path.join(dest, 'package.json')
return readFileAsync(pjson, 'utf8')
.then(str => truncateAsync(pjson)
Expand Down
3 changes: 2 additions & 1 deletion lib/util/opt-check.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ module.exports = figgyPudding({
tag: { default: 'latest' },
uid: {},
umask: {},
where: {}
where: {},
unmodified: {}
}, {
other (key) {
return key.match(AUTH_REGEX) || key.match(SCOPE_REGISTRY_REGEX)
Expand Down