filaraujo / gulp-i18n-localize

localization plugin for gulp
MIT License
8 stars 5 forks source link

Issues with paths on Windows #1

Closed dirkluijk closed 8 years ago

dirkluijk commented 8 years ago

Hi,

The generated (translated) files are not placed in the correct folders. I suspect this is a Windows-specific issue.

Using: "gulp-i18n-localize": "^1.1.0" On: Windows 7

I am not that good with JS. It would be great if someone can track this bug down. :+1:

filaraujo commented 8 years ago

can you provide the path that they are placed?

itmm commented 7 years ago

I also got a report with a problem under windows. Here is the call stack:

[20:41:27] gulp-i18n-localize: ${{ base.PLAIN_TEXT }}$ translation missing in en
events.js:160
     throw er; // Unhandled 'error' event
     ^

Error: no writecb in Transform class
   at afterTransform (C:\Users\marqu\cryptool-online\_ctoApps\vigenere\node_modules\through2\node_modules\readable-stream\lib\_stream_transform.js:74:40)
   at TransformState.afterTransform (C:\Users\marqu\cryptool-online\_ctoApps\vigenere\node_modules\through2\node_modules\readable-stream\lib\_stream_transform.js:58:12)
   at DestroyableTransform.fileInclude [as _transform] (C:\Users\marqu\cryptool-online\_ctoApps\vigenere\node_modules\gulp-file-include\lib\index.js:57:9)
   at DestroyableTransform.Transform._read (C:\Users\marqu\cryptool-online\_ctoApps\vigenere\node_modules\through2\node_modules\readable-stream\lib\_stream_transform.js:159:10)
   at DestroyableTransform.Transform._write (C:\Users\marqu\cryptool-online\_ctoApps\vigenere\node_modules\through2\node_modules\readable-stream\lib\_stream_transform.js:147:83)
   at doWrite (C:\Users\marqu\cryptool-online\_ctoApps\vigenere\node_modules\through2\node_modules\readable-stream\lib\_stream_writable.js:338:64)
   at writeOrBuffer (C:\Users\marqu\cryptool-online\_ctoApps\vigenere\node_modules\through2\node_modules\readable-stream\lib\_stream_writable.js:327:5)
   at DestroyableTransform.Writable.write (C:\Users\marqu\cryptool-online\_ctoApps\vigenere\node_modules\through2\node_modules\readable-stream\lib\_stream_writable.js:264:11)
   at write (C:\Users\marqu\cryptool-online\_ctoApps\vigenere\node_modules\vinyl-fs\node_modules\readable-stream\lib\_stream_readable.js:623:24)
   at flow (C:\Users\marqu\cryptool-online\_ctoApps\vigenere\node_modules\vinyl-fs\node_modules\readable-stream\lib\_stream_readable.js:632:7) 

The same works fine under macOS and Rasbian. Do I need a special file encoding for Windows?

itmm commented 7 years ago

if it helps, the files are accessible in this public github project:

https://github.com/fschell/cryptool-online

under _ctoApps/vigenere/src/common/locales/en/base.json and it contains PLAIN_TEXT.