From 45cd92679a69d9f21928df31f1d8b250bfd8f213 Mon Sep 17 00:00:00 2001 From: crupest Date: Sat, 23 Jan 2021 02:05:42 +0800 Subject: chore: Re-pnpify. --- FrontEnd/.yarn/sdks/prettier/index.js | 10 ++++++++++ FrontEnd/.yarn/sdks/prettier/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) mode change 100644 => 100755 FrontEnd/.yarn/sdks/prettier/index.js (limited to 'FrontEnd/.yarn/sdks/prettier') diff --git a/FrontEnd/.yarn/sdks/prettier/index.js b/FrontEnd/.yarn/sdks/prettier/index.js old mode 100644 new mode 100755 index 984baf1d..80134e18 --- a/FrontEnd/.yarn/sdks/prettier/index.js +++ b/FrontEnd/.yarn/sdks/prettier/index.js @@ -14,6 +14,16 @@ if (existsSync(absPnpApiPath)) { // Setup the environment to be able to require prettier/index.js require(absPnpApiPath).setup(); } + + const pnpifyResolution = require.resolve(`@yarnpkg/pnpify`, {paths: [dirname(absPnpApiPath)]}); + if (typeof global[`__yarnpkg_sdk_is_using_pnpify__`] === `undefined`) { + Object.defineProperty(global, `__yarnpkg_sdk_is_using_pnpify__`, {configurable: true, value: true}); + + process.env.NODE_OPTIONS += ` -r ${pnpifyResolution}`; + + // Apply PnPify to the current process + absRequire(pnpifyResolution).patchFs(); + } } // Defer to the real prettier/index.js your application uses diff --git a/FrontEnd/.yarn/sdks/prettier/package.json b/FrontEnd/.yarn/sdks/prettier/package.json index 6a957f27..adf33891 100644 --- a/FrontEnd/.yarn/sdks/prettier/package.json +++ b/FrontEnd/.yarn/sdks/prettier/package.json @@ -1,6 +1,6 @@ { "name": "prettier", - "version": "2.1.2-pnpify", + "version": "2.2.1-pnpify", "main": "./index.js", "type": "commonjs" } -- cgit v1.2.3