-1

I want convert some wordpress .po language files to .json format and used wp-cli but PO files converted to multi files of json but I need to a single json file.

So installed po2json using:

npm install po2json

I am getting this error:

C:\Users\Mehdi\Desktop\po2json 1.0.0>po2json translation.po translation.json
'po2json' is not recognized as an internal or external command,
operable program or batch file.

Can anybody help me to use po2json easily?

Sercan
  • 4,739
  • 3
  • 17
  • 36
Hadi Rajabi
  • 67
  • 1
  • 12

1 Answers1

1

I have tried to install https://openbase.com/js/@myrotvorets/po2json using:

npm i @myrotvorets/po2json

And finally I got the output with the following code:

po2json sourcefile.po > destfile.json
Hadi Rajabi
  • 67
  • 1
  • 12