Skip to content

Commit

Permalink
feat: do not alter file ownership
Browse files Browse the repository at this point in the history
BREAKING CHANGE: this package no longer attempts to change file ownership automatically
  • Loading branch information
nlf authored and lukekarrys committed Oct 17, 2022
1 parent 475e9b6 commit 58065bc
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 7 deletions.
1 change: 0 additions & 1 deletion DEPENDENCIES.md
Original file line number Diff line number Diff line change
Expand Up @@ -544,7 +544,6 @@ graph LR;
libnpmexec-->bin-links;
libnpmexec-->chalk;
libnpmexec-->minify-registry-metadata;
libnpmexec-->mkdirp-infer-owner;
libnpmexec-->mkdirp;
libnpmexec-->npm-package-arg;
libnpmexec-->npmcli-arborist["@npmcli/arborist"];
Expand Down
1 change: 0 additions & 1 deletion package-lock.json
Original file line number Diff line number Diff line change
Expand Up @@ -13862,7 +13862,6 @@
"@npmcli/fs": "^2.1.1",
"@npmcli/run-script": "^4.2.0",
"chalk": "^4.1.0",
"mkdirp-infer-owner": "^2.0.0",
"npm-package-arg": "^9.0.1",
"npmlog": "^6.0.2",
"pacote": "^14.0.0",
Expand Down
4 changes: 2 additions & 2 deletions workspaces/libnpmexec/lib/file-exists.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
const { resolve } = require('path')
const fs = require('@npmcli/fs')
const { stat } = require('fs/promises')
const walkUp = require('walk-up-path')

const fileExists = async (file) => {
try {
const res = await fs.stat(file)
const res = await stat(file)
return res.isFile()
} catch {
return false
Expand Down
4 changes: 2 additions & 2 deletions workspaces/libnpmexec/lib/index.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
'use strict'

const { mkdir } = require('fs/promises')
const { promisify } = require('util')

const Arborist = require('@npmcli/arborist')
const ciDetect = require('@npmcli/ci-detect')
const crypto = require('crypto')
const log = require('proc-log')
const mkdirp = require('mkdirp-infer-owner')
const npa = require('npm-package-arg')
const npmlog = require('npmlog')
const pacote = require('pacote')
Expand Down Expand Up @@ -205,7 +205,7 @@ const exec = async (opts) => {
.digest('hex')
.slice(0, 16)
const installDir = resolve(npxCache, hash)
await mkdirp(installDir)
await mkdir(installDir, { recursive: true })
const npxArb = new Arborist({
...flatOptions,
path: installDir,
Expand Down
1 change: 0 additions & 1 deletion workspaces/libnpmexec/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@
"@npmcli/fs": "^2.1.1",
"@npmcli/run-script": "^4.2.0",
"chalk": "^4.1.0",
"mkdirp-infer-owner": "^2.0.0",
"npm-package-arg": "^9.0.1",
"npmlog": "^6.0.2",
"pacote": "^14.0.0",
Expand Down

0 comments on commit 58065bc

Please sign in to comment.