diff --git a/lib/index.js b/lib/index.js index 7c07ded..8a18d71 100644 --- a/lib/index.js +++ b/lib/index.js @@ -6,7 +6,7 @@ import BinWrapper from '@xhmikosr/bin-wrapper'; import { packageConfig } from 'pkg-conf'; const pkg = new URL('../package.json', import.meta.url); -const { hugoVersion } = JSON.parse(await fs.readFile(pkg)); +const { hugoVersion } = JSON.parse(await fs.readFile(pkg, 'utf8')); const destDir = path.join(fileURLToPath(new URL('../vendor/', import.meta.url))); const binName = process.platform === 'win32' ? 'hugo.exe' : 'hugo';