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

Fix: Allow for spaces in file path #2

Merged
merged 3 commits into from
Aug 10, 2017

Conversation

GaryJones
Copy link
Contributor

If a path to a .po file had a space, then the .../tmp/....mo would also have a space, but this then couldn't be opened by msgfmt as that uses spaces to delimit its arguments.

Here's what it looks like without the fix:

Screenshot showing msgfmt failing due to the space

And with the fix:

screenshot showing gulp-potomo working correctly again even with space

If a path to a `.po` file had a space, then the `.../tmp/....mo` would also have a space, but this then couldn't be opened by `msgfmt` as that uses spaces to delimit its arguments.
@felixzapata
Copy link
Owner

hi @GaryJones thanks for the pull request, can you add a new test with the pull request?

@GaryJones
Copy link
Contributor Author

@felixzapata Done :-)

@felixzapata
Copy link
Owner

felixzapata commented Aug 9, 2017

I will take a look as soon as possible. I have problems (related with Xcode and brew) installing gettext in a different computer.

module.exports = gulpPotomo;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you remove the extra line?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's usually good practice to have the extra line at the end of files, so that it doesn't flag up the lack of newline character (shown as the red character above, but also shown as "No newline at end of file".

test/test.js Outdated
actual.should.equal(expected);
done();
}));

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you remove the blank lines (90 and 91) and keep the space columns like the test number 4

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I can fix this one up.

@felixzapata
Copy link
Owner

felixzapata commented Aug 9, 2017

hi @GaryJones , finally I resolved my problems with gettext using other laptop. I've tested your changes but please fix the minor comments in the pull request and I will merge it.

@GaryJones
Copy link
Contributor Author

@felixzapata The code in the test file was already fairly inconsistent with regard to indentation and clear line spaces, so I've hopefully tidied up all the whitespace to your preference.

@felixzapata felixzapata merged commit 3eb003b into felixzapata:master Aug 10, 2017
@felixzapata
Copy link
Owner

@GaryJones I've released the version 1.0.3

@GaryJones GaryJones deleted the patch-1 branch August 10, 2017 07:07
@GaryJones
Copy link
Contributor Author

Thank you :-)

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

Successfully merging this pull request may close these issues.

2 participants