uniswap-interface-uncensored/prei18n-extract.js
Bruno Crosier 8b38a9c4e0
fix: add crossplatform prei18n-extract script (#3728)
* fix: 🐛 add crossplatform `prei18n-extract` script

* fix: 🚨 add newline

* Revert "fix: 🐛 add crossplatform `prei18n-extract` script"

This reverts commit 201bd2308a3caf648368b3945d5b73d8cb46c816.

* build: 📦 add `shx` as dev dep, use it in `prei18n:extract` script

* fix: 🐛 use platform-specific commands for prei18n-extract
2022-07-12 18:51:24 +02:00

10 lines
307 B
JavaScript

// eslint-disable-next-line @typescript-eslint/no-var-requires
const exec = require('child_process').exec
const isWindows = process.platform === 'win32' || /^(msys|cygwin)$/.test(process.env.OSTYPE)
if (isWindows) {
exec(`type nul > src/locales/en-US.po`)
} else {
exec(`touch src/locales/en-US.po`)
}