diff --git a/dist/index.js b/dist/index.js index c1c77fc..70480b3 100644 Binary files a/dist/index.js and b/dist/index.js differ diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 8b04e18..c3b580b 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1,97 +1,3 @@ ---- -lockfileVersion: '9.0' - -importers: - - .: - configDependencies: {} - packageManagerDependencies: - '@pnpm/exe': - specifier: 10.32.1 - version: 10.32.1 - pnpm: - specifier: 10.32.1 - version: 10.32.1 - -packages: - - '@pnpm/exe@10.32.1': - hasBin: true - resolution: {integrity: sha512-baEtwHeZwmZAdBuuDDL6tbdGg5KpxhPxr3QFfYTGXvY6ws+Z1bN0mQ7ZjcaXBSC1HuLpVXnZ6NsBiaZ2DMv4vg==} - - '@pnpm/linux-arm64@10.32.1': - cpu: [arm64] - hasBin: true - os: [linux] - resolution: {integrity: sha512-6uB0B+XvunQwHGzIMk2JCkl4Ur6BtM4XbJSwB/mgpWmXDoX/KTJmgx2lodcTjgJSGSySCHfIVuTR9sj/F2D4EA==} - - '@pnpm/linux-x64@10.32.1': - cpu: [x64] - hasBin: true - os: [linux] - resolution: {integrity: sha512-AM2tv23Fg7h+nV+adqA/SkZKUysSIEetHfBwYFl8ArgdgkqbGoQy0rAOdKYQBb920CqfexXfI8OA8kPCzRxYng==} - - '@pnpm/macos-arm64@10.32.1': - cpu: [arm64] - hasBin: true - os: [darwin] - resolution: {integrity: sha512-Zr4JkhRbtGVsYgbuGZO0dq/6FPOn072Pdo0ubmqWtc14cUATKgAJD7efG03yqr3MLgtwFHgdtUzZ1WsaYAtUTA==} - - '@pnpm/macos-x64@10.32.1': - cpu: [x64] - hasBin: true - os: [darwin] - resolution: {integrity: sha512-Yk6q3oFDu//OniXJxfTSHo+aew1LX81FcbzJAtEkcCeTQ0SLbQT6J3QiOMNikp8n8IjNhsy+bn2bdkUxaw+akA==} - - '@pnpm/win-arm64@10.32.1': - cpu: [arm64] - hasBin: true - os: [win32] - resolution: {integrity: sha512-P8rsP5IUetpYjr2iwggoswL2qUukYrJoToXWuMyo8immn58CsYxaXsHVQ1Oq1R3XMfmGGWTXLsiJuQ7H991MRg==} - - '@pnpm/win-x64@10.32.1': - cpu: [x64] - hasBin: true - os: [win32] - resolution: {integrity: sha512-i24GwbtBO8ojrhp8WWimX7NgZs0UKH1171oRt6qcRL+a+FxE0Eggv2y0KP7ZI7F3+LZMarwr3tnYsZryfciUOg==} - - pnpm@10.32.1: - engines: {node: '>=18.12'} - hasBin: true - resolution: {integrity: sha512-pwaTjw6JrBRWtlY+q07fHR+vM2jRGR/FxZeQ6W3JGORFarLmfWE94QQ9LoyB+HMD5rQNT/7KnfFe8a1Wc0jyvg==} - -snapshots: - - '@pnpm/exe@10.32.1': - optionalDependencies: - '@pnpm/win-arm64': 10.32.1 - '@pnpm/linux-arm64': 10.32.1 - '@pnpm/win-x64': 10.32.1 - '@pnpm/macos-x64': 10.32.1 - '@pnpm/macos-arm64': 10.32.1 - '@pnpm/linux-x64': 10.32.1 - - '@pnpm/linux-arm64@10.32.1': - optional: true - - '@pnpm/linux-x64@10.32.1': - optional: true - - '@pnpm/macos-arm64@10.32.1': - optional: true - - '@pnpm/macos-x64@10.32.1': - optional: true - - '@pnpm/win-arm64@10.32.1': - optional: true - - '@pnpm/win-x64@10.32.1': - optional: true - - pnpm@10.32.1: {} - ---- lockfileVersion: '9.0' settings: diff --git a/src/install-pnpm/bootstrap/exe-lock.json b/src/install-pnpm/bootstrap/exe-lock.json deleted file mode 100644 index 3d755d9..0000000 --- a/src/install-pnpm/bootstrap/exe-lock.json +++ /dev/null @@ -1,147 +0,0 @@ -{ - "name": "bootstrap-exe", - "lockfileVersion": 3, - "requires": true, - "packages": { - "": { - "dependencies": { - "@pnpm/exe": "latest" - } - }, - "node_modules/@pnpm/exe": { - "version": "10.32.1", - "resolved": "https://registry.npmjs.org/@pnpm/exe/-/exe-10.32.1.tgz", - "integrity": "sha512-baEtwHeZwmZAdBuuDDL6tbdGg5KpxhPxr3QFfYTGXvY6ws+Z1bN0mQ7ZjcaXBSC1HuLpVXnZ6NsBiaZ2DMv4vg==", - "hasInstallScript": true, - "license": "MIT", - "bin": { - "pnpm": "pnpm" - }, - "funding": { - "url": "https://opencollective.com/pnpm" - }, - "optionalDependencies": { - "@pnpm/linux-arm64": "10.32.1", - "@pnpm/linux-x64": "10.32.1", - "@pnpm/macos-arm64": "10.32.1", - "@pnpm/macos-x64": "10.32.1", - "@pnpm/win-arm64": "10.32.1", - "@pnpm/win-x64": "10.32.1" - } - }, - "node_modules/@pnpm/linux-arm64": { - "version": "10.32.1", - "resolved": "https://registry.npmjs.org/@pnpm/linux-arm64/-/linux-arm64-10.32.1.tgz", - "integrity": "sha512-6uB0B+XvunQwHGzIMk2JCkl4Ur6BtM4XbJSwB/mgpWmXDoX/KTJmgx2lodcTjgJSGSySCHfIVuTR9sj/F2D4EA==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "bin": { - "pnpm": "pnpm" - }, - "funding": { - "url": "https://opencollective.com/pnpm" - } - }, - "node_modules/@pnpm/linux-x64": { - "version": "10.32.1", - "resolved": "https://registry.npmjs.org/@pnpm/linux-x64/-/linux-x64-10.32.1.tgz", - "integrity": "sha512-AM2tv23Fg7h+nV+adqA/SkZKUysSIEetHfBwYFl8ArgdgkqbGoQy0rAOdKYQBb920CqfexXfI8OA8kPCzRxYng==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "linux" - ], - "bin": { - "pnpm": "pnpm" - }, - "funding": { - "url": "https://opencollective.com/pnpm" - } - }, - "node_modules/@pnpm/macos-arm64": { - "version": "10.32.1", - "resolved": "https://registry.npmjs.org/@pnpm/macos-arm64/-/macos-arm64-10.32.1.tgz", - "integrity": "sha512-Zr4JkhRbtGVsYgbuGZO0dq/6FPOn072Pdo0ubmqWtc14cUATKgAJD7efG03yqr3MLgtwFHgdtUzZ1WsaYAtUTA==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "bin": { - "pnpm": "pnpm" - }, - "funding": { - "url": "https://opencollective.com/pnpm" - } - }, - "node_modules/@pnpm/macos-x64": { - "version": "10.32.1", - "resolved": "https://registry.npmjs.org/@pnpm/macos-x64/-/macos-x64-10.32.1.tgz", - "integrity": "sha512-Yk6q3oFDu//OniXJxfTSHo+aew1LX81FcbzJAtEkcCeTQ0SLbQT6J3QiOMNikp8n8IjNhsy+bn2bdkUxaw+akA==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "bin": { - "pnpm": "pnpm" - }, - "funding": { - "url": "https://opencollective.com/pnpm" - } - }, - "node_modules/@pnpm/win-arm64": { - "version": "10.32.1", - "resolved": "https://registry.npmjs.org/@pnpm/win-arm64/-/win-arm64-10.32.1.tgz", - "integrity": "sha512-P8rsP5IUetpYjr2iwggoswL2qUukYrJoToXWuMyo8immn58CsYxaXsHVQ1Oq1R3XMfmGGWTXLsiJuQ7H991MRg==", - "cpu": [ - "arm64" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "bin": { - "pnpm": "pnpm.exe" - }, - "funding": { - "url": "https://opencollective.com/pnpm" - } - }, - "node_modules/@pnpm/win-x64": { - "version": "10.32.1", - "resolved": "https://registry.npmjs.org/@pnpm/win-x64/-/win-x64-10.32.1.tgz", - "integrity": "sha512-i24GwbtBO8ojrhp8WWimX7NgZs0UKH1171oRt6qcRL+a+FxE0Eggv2y0KP7ZI7F3+LZMarwr3tnYsZryfciUOg==", - "cpu": [ - "x64" - ], - "license": "MIT", - "optional": true, - "os": [ - "win32" - ], - "bin": { - "pnpm": "pnpm.exe" - }, - "funding": { - "url": "https://opencollective.com/pnpm" - } - } - } -} diff --git a/src/install-pnpm/run.ts b/src/install-pnpm/run.ts index c4cabaf..e626626 100644 --- a/src/install-pnpm/run.ts +++ b/src/install-pnpm/run.ts @@ -7,10 +7,8 @@ import util from 'util' import { Inputs } from '../inputs' import { parse as parseYaml } from 'yaml' import pnpmLock from './bootstrap/pnpm-lock.json' -import exeLock from './bootstrap/exe-lock.json' -const BOOTSTRAP_PNPM_PACKAGE_JSON = JSON.stringify({ private: true, dependencies: { pnpm: pnpmLock.packages['node_modules/pnpm'].version } }) -const BOOTSTRAP_EXE_PACKAGE_JSON = JSON.stringify({ private: true, dependencies: { '@pnpm/exe': exeLock.packages['node_modules/@pnpm/exe'].version } }) +const BOOTSTRAP_PACKAGE_JSON = JSON.stringify({ private: true, dependencies: { pnpm: pnpmLock.packages['node_modules/pnpm'].version } }) export async function runSelfInstaller(inputs: Inputs): Promise { const { version, dest, packageJsonFile, standalone } = inputs @@ -21,10 +19,8 @@ export async function runSelfInstaller(inputs: Inputs): Promise { await rm(bootstrapDir, { recursive: true, force: true }) await mkdir(bootstrapDir, { recursive: true }) - const lockfile = standalone ? exeLock : pnpmLock - const packageJson = standalone ? BOOTSTRAP_EXE_PACKAGE_JSON : BOOTSTRAP_PNPM_PACKAGE_JSON - await writeFile(path.join(bootstrapDir, 'package.json'), packageJson) - await writeFile(path.join(bootstrapDir, 'package-lock.json'), JSON.stringify(lockfile)) + await writeFile(path.join(bootstrapDir, 'package.json'), BOOTSTRAP_PACKAGE_JSON) + await writeFile(path.join(bootstrapDir, 'package-lock.json'), JSON.stringify(pnpmLock)) const npmExitCode = await runCommand('npm', ['ci', '--ignore-scripts'], { cwd: bootstrapDir }) if (npmExitCode !== 0) {