diff --git a/lib/cache-install-dir.js b/lib/cache-install-dir.js index 1bee289..9e30d62 100644 --- a/lib/cache-install-dir.js +++ b/lib/cache-install-dir.js @@ -12,7 +12,7 @@ const cacheInstallDir = ({ cache, packages }) => { const getHash = (packages) => crypto.createHash('sha512') - .update(packages.sort((a, b) => a.localeCompare(b)).join('\n')) + .update(packages.sort((a, b) => a.localeCompare(b, 'en')).join('\n')) .digest('hex') .slice(0, 16) diff --git a/lib/index.js b/lib/index.js index 0bab753..a48c654 100644 --- a/lib/index.js +++ b/lib/index.js @@ -143,7 +143,7 @@ const exec = async (opts) => { }, })) .map(mani => mani._from) - .sort((a, b) => a.localeCompare(b)) + .sort((a, b) => a.localeCompare(b, 'en')) // no need to install if already present if (add.length) {