Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug at splitting file content to lines #19

Open
moyuanz opened this issue Aug 31, 2020 · 0 comments
Open

bug at splitting file content to lines #19

moyuanz opened this issue Aug 31, 2020 · 0 comments

Comments

@moyuanz
Copy link

moyuanz commented Aug 31, 2020

const sourceByLine = source.split(os.EOL)

There's bug in above code that os.EOL need to be replaced by '\n'. In case in Windows system, but line is broken only with '\n', os.EOL in Windows is '\r\n'.

const endBlock = /// #endif$/

This above still have bug that change it like this const endBlock = /// #endif/

@moyuanz moyuanz changed the title bug at split file content to lines bug at splitting file content to lines Aug 31, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant